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
 Paramters not mandatory

Author  Topic 

1sabine8
Posting Yak Master

130 Posts

Posted - 2010-01-04 : 09:30:17
Hi,
I am building a dataset with a query where i need to filter values by different parameters values. I need the parameters not to be mandatory so if a parameter is not filled, the query will return records filtered by the filled parameters. How should i build the query and what should i specify in the parameters?
thanks in advance

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2010-01-04 : 09:38:05
where (@param is null or your_column = @param)


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page
   

- Advertisement -