Tried of entering the same data

  • Thread starter Thread starter artross
  • Start date Start date
A

artross

Guest
So, I made a table which just contains system parameters. It has one entry at the moment called "yyyy" value is "yyyy".

To keep from having to enter data which is always the same for the DateDiff caculation, I changed my query to look like this :
Age: DateDiff([System Variables]![YYYY],[Student Date of Birth],Date())

It does not ask to input the 'yyyy' (good), but stops all output from the query (which means it probably has null input for the 'yyyy').

How can I feed the 'yyyy' parameter to the query programactically rather than having to enter it each time? It is always the same.
 
Hello

If i understand this correctly what you are doing is running a query using the datediff function with one static piece of information i.e YYYY for the year (the one in your table) and two variable dates.

If you want the static data in your query could you not just write it in??


DateDiff("y",[Student Date of Birth],Date())


if you need to vary the datediff type i.e "d" or "q" then you would probably ask the user for the data selection from say a list


hope that helps

Chris
 

Users who are viewing this thread

Back
Top Bottom