Quantcast
Channel: SQL Server Reporting Services, Power View forum
Viewing all articles
Browse latest Browse all 10045

ssrs 2008 using temp tables

$
0
0

The questions apply to using temp tables when executing 5 datasets in the same main ssrs report.

Here is the description of the ssrs 2208 report:

In a new SSRS 2008 report, I am allowing the user to select which report they  would like to see generated by selecting the report name from a dropdown list. This is a multi-valued parameter and the parameter name is called 'report'. The default value is for all 5 reports to be selected.

All 5 reports are  on the 'main' report. There will be no subreports. Each report has its own unique matrix and the matrix is  visibile based upon what is selected in the parameter called 'report'.

The following is how I make all 5 reports show up as a default selection.

1.Right-click the multiple parameter ‘repot’ to open the Properties dialog box.

2.Specify the values below in the Available values:
 Label: report1                                                 Value: report1
 Label: report2                                                 Value: report2
 Label: report3                                                 Value: report3
 Label: report4                                                 Value: report4
 Label: report5                                                 Value: report5

3.Specify the values below as the Default Values:
 report1   report2   report3   report4   report5

4.Right-click the ‘report1’ to open the Tablix Properties dialog box.

5.Select Visibility in the left pane, type the expression below in the “Show or hide based on an expression” textbox:
 =iif(InStr(join(Parameters!report.Value,","),"report1")>0,false,true)

6.Use the expressions below to control the visibility of the ‘report2’, ‘report3’, ‘report4’, ’report5’:
 =iif(InStr(join(Parameters!report.Value,","),"report2")>0,false,true)
 =iif(InStr(join(Parameters!report.Value,","),"report3")>0,false,true)
 =iif(InStr(join(Parameters!report.Value,","),"report4")>0,false,true)
 =iif(InStr(join(Parameters!report.Value,","),"report5")>0,false,true)

The questions are:
1.  Can I use a temp table called '##temp' in the first dataset and have the other 4 datasets refer to '##temp'? I am asking the question since all 5 datasets use the same stored procedure. If this possible, can you tell me how to setup the code?
2. When I am running visual studio 2008 and create a temp table called '#test'. I get results. However if I change the sql for the dataset and rerun the query, the results from the orginal temp table remains. The column headers remain the same, but the data that is returned is from the original query before the dataset was changed. I found out that I have to stop by visual studio 2008 session, and start a new session for the new values for the dataset to be returned. In the original dataset code I had the statement drop #test and that did not work. Thus can you tell me how to solve this issue?




Viewing all articles
Browse latest Browse all 10045

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>