T teabags Registered User. Local time Today, 00:48 Joined Jun 29, 2006 Messages 21 Aug 1, 2006 #1 I am passing a sql statement through vb and I am getting a criteria mismatch expression. Between '" & DStart & "' And '" & DFinish & "' DStart and Finish both correspond to numeric fields in an access database
I am passing a sql statement through vb and I am getting a criteria mismatch expression. Between '" & DStart & "' And '" & DFinish & "' DStart and Finish both correspond to numeric fields in an access database
pbaldy Wino Moderator Staff member Local time Today, 00:48 Joined Aug 30, 2003 Messages 36,272 Aug 1, 2006 #2 Numeric fields should not be surrounded by single quotes.
Bodisathva Registered User. Local time Today, 03:48 Joined Oct 4, 2005 Messages 1,274 Aug 1, 2006 #3 ...date literals need to be surrounded by '#' i.e. a string representing today's date is Code: "08/01/2006" or '08/01/2006' but a date object representing today's date is Code: #08/01/2006#
...date literals need to be surrounded by '#' i.e. a string representing today's date is Code: "08/01/2006" or '08/01/2006' but a date object representing today's date is Code: #08/01/2006#