Access Cheat Sheet

These are from ye olde Access 97 days and may no longer apply.

COUNT DISTINCT isn’t supported

To get around it: SELECT COUNT(1) FROM (SELECT DISTINCT column FROM table)


When using multiple ANSI joins, you must surround each set in parentheses.

FROM (users INNER JOIN messages ON = messages.idUser)
INNER JOIN topics ON messages.idTopic =

Object Names

If there are queer characters or reserved words in your table/query names, you can reference them in SQL statements by surrounding the name with square brackets, just like SQL Server.

SELECT email, [date] FROM [List Members]


Surround dates in SQL with #.

SELECT * FROM users WHERE joined > #3/4/2002#


Leave a Reply

Your email address will not be published. Required fields are marked *