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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cascading list & include wildcard * for All options, possible?

Status
Not open for further replies.

scotton

Technical User
Jun 20, 2005
27
US
This is the first time I've created a cascading list and it's broken down with employee status, then location, followed by department. It works except for the fact that sometimes the end user may want to run it for all status's, all locations and all departments or some combination of those.
How can I incorporate the wildcard * for all choices within a dynamic parameter?

TIA,

Sarah
 

What version of CR are you using? CR2008 introduced optional parameters, which might be of some use to you on this one.

Status seems to be the odd value here - there probably aren't that many possible values, so it may make more sense to have that as its own parameter. That will give you more flexibility.

As for location, create a command object but do not link it to any other table:

select 'All Locations', 'All Departments"
union
select location, department from yourtable


Base the dynamic parameter on the command. Select statement would be similar to:


if {?Status} = "All Stati" then true else table.status = {?Status}
and
if {?Department = "All Departments" then true else table.department = {?Department}



 
A little correction:

select location, department
from yourtable
union
select 'All Locations', 'All Departments'
from yourtable

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top