Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Queries / July 2006

Tip: Looking for answers? Try searching our database.

Default Query criteria

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Bill - 19 Jul 2006 21:34 GMT
I have a database where there is one field where each month the criteria
changes but stays constant for that whole month. For instance, during october
I'd want to always be searching for and entering data that deals with
Pumpkins (stored somewhere else in a separate table) But next month I'll want
that default to be chairs, or something of that nature. Is there a way I can
set a default value that queries will always know to use so I can set it once
a month and not be always entering "pumpkins".

Thoughts? Thank you in advance
Jeff L - 19 Jul 2006 22:00 GMT
Make a criteria table (ID, Criteria) with 1-12 in the ID and your
criteria in Criteria.  Then in the criteria of your field in your
query, put
Dlookup("Criteria", "YourCriteriaTable", "ID = " & Month(Date()))

Hope that helps!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.