report associates with different query

fanfan2

Registered User.
Local time
Today, 03:59
Joined
Feb 26, 2007
Messages
61
I used the wizard to create a report base on a query. I need to have a whole bunch of similar reports (same formats, same type of data, but different query. For example I generated a report for Jan, now I want to generate reports for other months). I saved this report as another report name, but how can I change the associated query to another query? Thanks.
 
You're going about it the wrong way. You should have one query and one report. That query should have a criteria that restricts it to a user selected time frame. Search on parameter queries.
 
Thanks, that's an excellent idea. But the user just wanted to select or enter the month, rather than enter the time range ( from, to ).
 
So? Have a combo that lists the months with the bound column just the number, and have this in the query:

WHERE Month(FieldName) = Forms!FormName.ComboName

You may need to do the same for year.
 
Thanks a lot. Sorry I'm not skillful at this. Do you mean a list box on the form? On the query, if I have other criterias could they be used together with the parameters? Another thing is, on the report aside from the part that was associated with that query, there are other text boxes that come from other queries (for summary). How can I make one report for every month (quarter) with different summary values? File is attached. Thank you so much.
 
Last edited:
You could certainly use this in conjunction with other criteria. Frankly, looking at your "r" and "h" queries, those should use parameters too. Why have 2 queries, when you can have one where the user picks "r" or "h" on the form? You know your requirements better than I do, but if you find yourself creating multiple queries and reports to handle different user selections, they can probably be handled with a single parameter query/report instead.
 

Users who are viewing this thread

Back
Top Bottom