MS Access Criteria Expressions for Queries.
(msdn examples criteria,expression values)
Field Expression Description
Date Between #1/5/95# And #1/10/95# Uses the Between...And operator
Date #2/2/95# where valu is 2-Feb-95.
Country In("Canada", "UK") Uses the In operator to display orders shipped to Canada or the UK.
ShipCountry Not "USA" Uses the Not operator to display orders shipped to countries other than the USA.
ShipName Like "S*" Orders shipped to customers whose name starts with the letter S.
CompanyName >="N" Displays orders shipped to companies whose name starts with the letters N through Z.
OrderID Right([OrderID], 2)=”99″ Uses the Right function to display orders with OrderID values ending in 99.
CompanyName Len([CompanyName])
/>Val(30) Uses the Len and Val functions to display orders for companies whose name is more than 30 characters long.
Is Null
Is Not Null
“Value”
“Value” or “Others”
Not “Value”
“” zero lenght string value.
Like “beginswith*”
Like “*endswith”
Like “[A-D]*” Begins with A, B, C or D
Like “*middlestring*”
Like “strin?” last letter unknown
Add New Comment
Thanks. Your comment is awaiting approval by a moderator.
Do you already have an account? Log in and claim this comment.
Add New Comment