Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 Reporting Services Development
 Static parameters with Null

Author  Topic 

chriskhan2000
Aged Yak Warrior

544 Posts

Posted - 2005-07-22 : 13:58:07
I have a report that references 3 separate databases. Depending on which database they pick, it will have different static parameters. In my ReportParameters, I can go and add the conditional expression for Name and Value so that depending on what database is pick, it will display those parameters. However some database has more parameters than others. Is it possible or how would I make it so that only the parameters within that specific database shows.

Let me show example:


Database1 Database2 Database3
Bob John Mary
Suzy Allen Jorden
Paul Art
Mike
Stanley



Here's my conditional expression:



=IIF(PARAMETERS!DATABASE.VALUE = "DATABASE1", "BOB", IIF(PARAMETERS!DATABASE.VALUE = "DATABASE2", "JOHN", "MARY"))

=IIF(PARAMETERS!DATABASE.VALUE = "DATABASE1", "SUZY", IIF(PARAMETERS!DATABASE.VALUE = "DATABASE2", "ALLEN", "JORDAN"))

=IIF(PARAMETERS!DATABASE.VALUE = "DATABASE1", "PAUL", IIF(PARAMETERS!DATABASE.VALUE = "DATABASE2", NULL, "ART"))

=IIF(PARAMETERS!DATABASE.VALUE = "DATABASE1", "MIKE", IIF(PARAMETERS!DATABASE.VALUE = "DATABASE2", NULL, NULL))

=IIF(PARAMETERS!DATABASE.VALUE = "DATABASE1", "STANLEY", IIF(PARAMETERS!DATABASE.VALUE = "DATABASE2", NULL, NULL))


So depending if they select which database, it will have those specific static parameters. However, I can't seem to use Null in my conditional expression. Anyone got any ideas?
   

- Advertisement -