Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report based on a user selected parameter

Status
Not open for further replies.

khan007

Programmer
Jun 10, 2003
103
CA
Im using CRXI, SQL 2008 database.

I have a question related to parameters.
Working on a report requires a single Parameter "Selection"
Rather than creating two different parameters, I need only one parameter with a drop down of two options "City" and "Status".
User will select only one, in order to run this report. There is no lookup table, data is coming from direct data fields.

When user will select City, a new parameter window (cascading) will appear with all cities and user will select multiple cities from there.

When user will select Status, a new parameter window will appear with all Status and user will select multiple Status from there.

Also, In this report I need two groups.

If user selects City, my groups order should be: City, then Status then data in detail section

If user selects Status, my groups order should be: Status, then City then data in detail section



 
Maybe this will help at least a little. I had a similar situation where user could either group by month or by year. My parameter GroupBy has two choices - month and year. then I have a formula called GroupByValuethat has a case statement.

select {GroupBy}
case 'month' : month({table.datefield})
case 'year' : year ({table.datefield})

So if the GroupBy parameter is month, it picks the month out of the date field. If year, then it picks the year.

Then I actually do the grouping on the GroupByValue field.

You might need a GroupByValue1 and a GroupByValue2 for the two group levels. Mine only has one grouping level.

That sort of addresses your second question; I'll be interested in any responses to the first question.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top