SQL code wrong-Help.

  • Thread starter Thread starter josh
  • Start date Start date
J

josh

TA,

Try this:
strSQL = "SELECT * FROM cumemployee " _
& " WHERE batch = '" _
& Me!Combo5.Value & "';"

You were missing the semi-colon which is required at the
end of every SQL statement. Try adding this line to help
debug a SQL statement:

debug.print strSQL

If you can't see what's wrong by looking at the SQL, then
copy it into a new query and let access try to fix it.

HTH,
Josh
 
josh said:
TA,

Try this:
strSQL = "SELECT * FROM cumemployee " _
& " WHERE batch = '" _
& Me!Combo5.Value & "';"

You were missing the semi-colon which is required at the
end of every SQL statement (snip)


Not true - either in the SQL window of the query designer, or when entering
SQL through code.

TC
 
Back
Top