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!

Parameter

Status
Not open for further replies.

xanra

IS-IT--Management
Jan 16, 2007
20
US
Hi, I'm running CR 11 and building this for an ASP.net application.

I have a discrete parameter {?site} which can have multiple values. If there are no values selected from the page, the parameter will have a value of -1 otherwise there will be a number(s) in the parameter in an array collection.

How can I setup the report expert so that if the parameter value is -1 it will include all sites otherwise if there are multiple values it will only display the pertinent sites.


Also there will be multiple parameters such as {?site} and I'm guessing if I can nail that down I will just need to create several If Else blocks to accommodate all the different deviations. If I'm mistaken can someone point me into the right direction.

Thanks in advance!
-Paul
 
(
if {?site} <> -1 then
{table.site} = {?site} else
if {?site} = -1 then
true
) and //etc.

You could also set it up like this:

(
(
{?site} <> -1 and
{Table.site} = {?site}
) or
{?site} = -1
) and //etc.

Whichever way you choose, you should go to database->show SQL query and make sure that the values are passing to the query.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top