SQL Date Syntax

holtzy
10-14-2002, 01:03 PM
I am using a VB6 front end on an Access 95 database. I'm trying to update a record, but it keeps giving me a data type mismatch error.RSSave2.Open "Update Candy Set DatePD = #" & varSaveDate & "# Where ID = '" & varID & "' AND dogs = '" & varSaveCase & "'", ConnThe data type of DatePD is Date/Time and varSaveDate is defined as Date. What am I doing wrong?

reboot
10-14-2002, 01:15 PM
If ID is numeric, and I'm assuming it is...

RSSave2.Open "Update Candy Set DatePD = #" & varSaveDate & "# Where ID = " & varID & " AND dogs = '" & varSaveCase & "'", Conn

holtzy
10-14-2002, 01:17 PM
Thank you reboot! That was driving me crazy.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum