Sickness database

pholligan

Registered User.
Local time
Today, 13:02
Joined
Jan 20, 2003
Messages
19
Hi

I am trying to write a sickness record database to make my life easier, but it only seems to be causing me lots of headaches!

I would like to run a Query which displays sickness records for a specific month. I have a 'First Day of Sickness' field which I would like to use in the criteria, but this is of the format 'dd/mm/yyyy', and I only want to have to either type in the month and year required, or ideally select a month from some sort of drop down box.

I'm sure this is relatively easy so I appologise for my lack of knowledge, but I am teaching myself as I go along and the 'Help' function doesn't exactly do what it says on the tin!

Many Thanks
Paul
 
Hi

How will you compensate for sickness that straddles month end?

Col
:cool:
 
Good point :-)

I will use the last day of the sickness rather than the first as the criteria. This will only then include sicknesses that are complete and have all the relevent data.

I have now managed to half solve the problem by using Format([Last Day of Sickness],"m/yy), and then [enter m/yy], but would still like to know if it is possible to enter this data via a drop down list or something.
 
You could have 2 ComboBoxes one for the year with the current year as default and the other to select a month. Then afterUpdate of the month comboBox you can run the query.

I'm still not sure you'll get what you want but keep us posted as to your results. Like I said earlier - will it pick up where the sickness started last month and extends into this month? It may work, I haven't got time at the moment to test it.

Col
:cool:
 
Hi again!

It does pick up on where the sickness started and shows all records where the last day ends in the specific month.

Now my problem is with the form! I can't seem to get the query to run with the criteria I set in the combo box on the form. After I select the month say from the combo box, the query runs, but not with the specified criteria.

What do I need to type in the criteria box in the query?

Thanks for all your help.

I do feel like I'm making progress though!

Paul
 

Users who are viewing this thread

Back
Top Bottom