A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Report and Query Parameters (Yet again!)



 
 
Thread Tools Display Modes
  #1  
Old August 22nd, 2006, 11:06 PM posted to microsoft.public.access.reports
[email protected]
external usenet poster
 
Posts: 1
Default Report and Query Parameters (Yet again!)

I'm not sure I understand the use of parameter queries and reports.

I have a query that returns calculations for Categories. There are 6
Categories (A,B,C,D,E,F).
There are also two Types of results Y and Z.

The result may not have all Categories or Types, because there may not
have values yet for a particular Category and Type.
I called this query qryTotals.

Here are the results....

Cat Typ Tot
--- --- ---
A Y 3
A Z 7
B Z 2
D Y 5
F Y 1
F Z 9


I need a report that gives me all Categories for a particular Type.
I would like the report to supply the Type value automatically. (Do not
want to prompt the user)


For example the results would be for Type ='Y'....

Cat Typ Tot
--- --- ---
A Y 3
B 0
C 0
D Y 5
E 0
F Y 1


So, I thought of making another query that gives me all Categories and
if there are no values for a particular Category, set it to zero using
nz(Total).

I created another query like this (pseudo QBE)...

Categories ------- qryTotals (Outer join to include all Categories)

and created a Type parameter in the qryTotals query.

When executed, the new query asks for the Type parameter and the
results are as shown above.


Is there a way to create a report or query that will automatically
supply the parameter to the
first query?

TIA

  #2  
Old August 23rd, 2006, 12:43 AM posted to microsoft.public.access.reports
dtoney
external usenet poster
 
Posts: 65
Default Report and Query Parameters (Yet again!)

under criteria... use Like "Y"

" wrote:

I'm not sure I understand the use of parameter queries and reports.

I have a query that returns calculations for Categories. There are 6
Categories (A,B,C,D,E,F).
There are also two Types of results Y and Z.

The result may not have all Categories or Types, because there may not
have values yet for a particular Category and Type.
I called this query qryTotals.

Here are the results....

Cat Typ Tot
--- --- ---
A Y 3
A Z 7
B Z 2
D Y 5
F Y 1
F Z 9


I need a report that gives me all Categories for a particular Type.
I would like the report to supply the Type value automatically. (Do not
want to prompt the user)


For example the results would be for Type ='Y'....

Cat Typ Tot
--- --- ---
A Y 3
B 0
C 0
D Y 5
E 0
F Y 1


So, I thought of making another query that gives me all Categories and
if there are no values for a particular Category, set it to zero using
nz(Total).

I created another query like this (pseudo QBE)...

Categories ------- qryTotals (Outer join to include all Categories)

and created a Type parameter in the qryTotals query.

When executed, the new query asks for the Type parameter and the
results are as shown above.


Is there a way to create a report or query that will automatically
supply the parameter to the
first query?

TIA


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:28 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.