cancel
Showing results for 
Search instead for 
Did you mean: 

Conditionally Dynamic Parameters

Former Member
0 Kudos

Is it possible to apply a condition to the values returned for a dynamic paramter? For example, I want users to select from a list of groups, but the table includes both student and teacher groups. How can I make the list of groups include only student groups?

Fuskie

Who's got a new gig...

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

I think we cannot add a filter condition for a dynamic prompt in designer. We can do it using business view by adding filter condition or If you want to add the condition at the designer level then add new command like

select data from table where field="students"

and remove the links between this command and the existing tables from your report and create a dynamic parameter using the field from your command.

I hope this helps!

Raghavendra

Answers (2)

Answers (2)

Former Member
0 Kudos

Hopefully you have a status field that contains "Student" or "Teacher" but if you have two separate fields one called "Teacher Name" and another field called "Student Name" you may have some problems....

If the 2nd case is true you could do two totally separate reports (one for teachers and one for students) and put them both into a main report as sub-reports. Put them into different report header sections (RHa and RHb for example) then create a parameter that asks the user if they want to see Students or Teachers.

Then simply conditionally suppress the sections in the report header where the subreports reside based on the parameter values.

So if someone chooses "Teachers" you'd conditionally suppress the section containing the "Students" report.

Hope this helps ya out!!!!

Former Member
0 Kudos

Thanks, Raghavendra. I usually try to avoid those warning alerts when mixing SQL commands with native table linking but your solution seems to be working. We'll have to see how it goes when I go from 378 rows to 378,000 rows.

Fuskie

Who appreciates all the suggestions...

Former Member
0 Kudos

Are you using CR Server BO Enterprise? If so, you can create your own Business View structure and LOV object to point your parameter to. Within that Business View you can restrict what data is returned in the LOV object.

Former Member
0 Kudos

No, this is just straight CR2008 Designer. The reports will be integrated into an as-yet undesigned web application interface.

Fuskie

Who had hoped this would be easier with CR2008's parameter improvements...