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.
    
        | 
                
                    | 
                            
                                | Author | Topic |  
                                    | jassieConstraint Violating Yak Guru
 
 
                                        332 Posts | 
                                            
                                            |  Posted - 2015-04-22 : 12:17:57 
 |  
                                            | In an existing ssrs 2012 report, I want to basically add the following logic to a new dataset that will be used by a new parameter called 'Inventory'.SELECT  DISTINCT Inv_number as value,  Inv_name as labelFROM s.dbo.fnUser( @endYear, 0, 0, 0)WHERE (@report is not null)order by  label,valueIn this ssrs report, there are 15 reports that can automatically be generated. I basically want this new parameter called 'Inventory' to only be activewhen the 4th report is selected to be generated. Thus in the query I listed above, how can I change the query to only be active when the 4th report is selected?I tried to change the where clause to (@report(4) is not null), but that did not work. Thus can you show me the sql I can use to accomplish my goal? |  |  
                                |  |  |  |