NitrO
12-09-02, 10:06
| Hi, Can anyone help please, I am trying to feed a date variable (sysDate) into an SQL string and cannot figure out why it wont work. e.g. This works fine for a variable which is a string - "SELECT * FROM OWNER WHERE ownerid= ' " & sstr & " ' " VB documentaion says this should work for a date "SELECT * FROM OWNER WHERE owndate = # sysDate # " But it throws a runtime error, i've tried everything I can think of with no luck. Any help would be greatly appreciated. Thanks in advance NitrO |