default value in parameter ssrs report
Hello, I created a parameter with available values from a dataset. By default i want it to display the maximum value. and then the user can select the dates if he does not like the default value. how to i do this. because when i tried to set the paramter default value to max(dataset!dt.value) it says expression canot be used. how to do this. SHould i create a dataset with maximum value and then assign it to this one. Please help thanks
May 7th, 2012 10:25am

You got it. Create another data set that returns one row (the max). Set your default value equal to that one.
Free Windows Admin Tool Kit Click here and download it now
May 7th, 2012 10:47am

Hi There You can do it with one dataset. Please bring the maximum value of your dataset with in the same dataset and attached your default value with the maximum value of the dataset I am putting screenshots foyr your help. I hope this will help Many thanks Syed Qazafi Anjum Please click "Mark as Answer" if this resolves your problem or "Vote as Helpful" if you find it helpful. SELECT [ColumnName] ,[ColumnID] ,maxColumn FROM [dbo].[GroupColumnname] inner join (select max([ColumnID]) as maxColumn FROM [dbo].[GroupColumnname] ) maximum on Columnid=[ColumnID]
May 7th, 2012 5:19pm

I would caution that the above could significantly degrade performance as the query that is aggregating the max value would run once for each row in the data set. breaking it out into its own dataset ensures that it only runs one time.
Free Windows Admin Tool Kit Click here and download it now
May 7th, 2012 5:46pm

I would caution that the above could significantly degrade performance as the query that is aggregating the max value would run once for each row in the data set. breaking it out into its own dataset ensures that it only runs one time. Hi BI Baracus I partially agree with you, this is just a work around if you do not want to use another dataset. To be honest it also depends how many values you have in parameter for your query performance to be adversely affected Many thanks Syed
May 7th, 2012 5:59pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics