adOpenStatic Logo
Navigation
Home
FAQ
Ken's Blog
Resources
Contact Ken
Copyright 2000 -



The 80040e07 error returned by ADO is usually accompanied by the following text:

Microsoft JET Database Engine error '80040e07'
Data type mismatch in criteria expression.

The error is usually caused by use of incorrect delimiters in your SELECT SQL query statement. The following table illustrates the delimiters required for each type of field:

Field Type (Access)

Field Type (SQL Server)

Delimiter

Text

Char, varChar

'

Numeric

Any numeric type

<none>

Date/Time

Any Date/Time

# (Access), ' (SQL Server)

An example SQL SELECT statement for use with MS Access would be:

SELECT field1
FROM table1
WHERE someTextField = 'someTextValue',
AND someNumericField = 5
AND someDateField = #2001/12/31#

Back to FAQ Listing | Homepage