Access 2010 VBA query a table and iterate through results -


i have query want execute against table. results want something. in head pseudo code is:

var q = "select * table condition"; var results = db.getresults(q); foreach (row r in results )     result 

how similar vba?

dao native access , far best general use. ado has place, unlikely it.

 dim rs dao.recordset  dim db database  dim strsql string   set db=currentdb   strsql = "select * table condition"   set rs = db.openrecordset(strsql)   while not rs.eof      rs.edit     rs!somefield = "abc"     rs!otherfield = 2     rs!adate = date()     rs.update      rs.movenext loop 

Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -