Report Template

lipin

Registered User.
Local time
Today, 00:56
Joined
May 21, 2002
Messages
149
I have created a report based on a crosstab query that shows the monthly worked hours of each employee. I will have to print the same report next month based on new data in another table. Is there an easy way to do this,(run the same query and report each month) without having to recreate them both for the new table?
 
I guess I am assuming that the new table for next month will simply be a copy of this month's table in structure only and only the data will change. Yes? If this is the case, I would copy the table you need to use and name the new table "TempCurrentMonth". Then, I would add that table to my existing query, and change all the fields to point to that table. (using the drop down boxes in design view that lists the available tables/queries) After you do that, delete the reference to the old table just for safety sake. Now your query is based on a table that you can always overwrite with the current data. You won't have to change where the report is getting the data from because it always uses the same query. You won't have to change the query ever again. You will only have to when necessary, delete the TempCurrentMonth table and then create it again with a copy of whatever month's table you need to use.

Tess
 
Base your Crosstab query on another query and use criteria to select the month in the first query.ie. [Enter Start Date]And [Enter End Date].
 
Jerry's suggestion would work if you are not storing each month's data in a seperate, new table. I personally don't know why you would make multiple tables, one for each month... but if that's the way you are doing it.... You may want to rethink that unless you have very specific reasons for it.
 
Thanks Tess I didnt see the based on new data in another table part.lipin Tess is right you really need to rethink your structure.
 

Users who are viewing this thread

Back
Top Bottom