Access error reference
Access error 3464: data type mismatch in criteria
A query, a filter or a DLookup stops on “Data type mismatch in criteria expression”. Access is comparing a field with a value of another type: text with a number, a date with a string. The code was often written for a field whose type has changed since.
The message

Run-time error '3464': Data type mismatch in criteria expression.
On a French Access: « Type de données incompatible dans l'expression du critère. » When the query is opened on screen rather than from code, the same message appears without the number.
Where it shows up
Wherever a criteria compares a field with a value: the Criteria row of a query, a WHERE clause built in VBA, DLookup, DCount, Me.Filter, rs.FindFirst, the criteria of DoCmd.OpenForm or DoCmd.OpenReport, and joins between two tables.
Common causes
- a number wrapped in quotes:
"[CustomerID]='" & Me.txtId & "'"whileCustomerIDis a Number field; - text without quotes:
"[ZipCode]=" & Me.txtZipon a Short Text field, which Access reads as a number; - a date passed as text:
"[OrderDate]='11/21/2026'"instead of a date between hash signs; - a lookup field: the table shows the label (“Boston”) but stores the number; the criteria compares that number with text;
- a join between fields of different types (Short Text on one side, Number on the other), common after importing from Excel;
- a calculated column that returns an error on some rows (
CDate,CLngon an empty value) and is then filtered: the error only shows with certain data.
How to reproduce and check it
- Open the table in Design view and note the data type of the field in the criteria (and, on the Lookup tab, whether it is a lookup list).
- Print the criteria as Access receives it:
Debug.Print strWherejust before the call, then read it in the Immediate window (Ctrl+G). - Paste that criteria into a query in SQL view: if the error comes back, the comparison is the cause; if not, look at a join or a calculated column.
How to fix it
Match the value to the field type: nothing around a number, quotes around text (doubling any quote inside), hash signs around a date in mm/dd/yyyy format. For a lookup field, compare the bound column (the number), not the label. For a join, give both fields the same type.
What Auscult reports
The diagnostic records 3464 wherever Access returns it during the run, with the form, report, query or button that produces it; one cause is counted once. Without running anything, it also flags criteria written in a way that will fail — a text field compared with a number, a value concatenated without quotes — among the statements that will fail the day they are used.
Related errors
- 3075 — syntax error (missing operator), the same concatenation when the value is empty
- 3061 — too few parameters, unquoted text taken for a field name
- 2001 — you canceled the previous operation, a DLookup whose criteria fails
- The Access error reference, code by code