MS-BI-SSRS,Passing Cascaded parameters to Drill Through report - reporting-services

I am trying to develop a report from cube,and it has one drill through report.when i click on sales amount field on main report,then it open the drill through report with details.Here i passed the (category,subcat,product)parameters(Cascaded) to drill through report in action part of main report.In my main report i have two columns .
columns are Level and Salesamount. Values are like
[-]category 100
[-]subcat 50
product 30
when i click on 100, parameters are passed & it open the detail report correctly, but when i click on 50,the values for subcat parameter is not getting values in detail report and same as the product also.
Here i used the expressions in parameter values
pCategory----iif(inscope(category),!fields.category.value,split(join(Parameters!category.value,","),","))
psubcat----iif(inscope(subcat),!fields.subcat.value,split(join(Parameters!subcat.value,","),","))
pproduct----iif(inscope(product),!fields.product.value,split(join(Parameters!product.value,","),","))
can any one plz reply me.Thanks in Advance

After Struggled 2 days , finally i made this. I just changed the expressions for the parameters, it worked fine.
pCategory= iif(inscope(category),!fields.category.value,split(join(Parameters!category.value,","),","))
psubcat= iif(inscope(subcat),!fields.subcat.value, lookupset(Fields!Category_ID.Value,Fields!Subcat_ID.Value,Fields!Subcat.Value,"dsMain")
pproduct= iif(inscope(product),!fields.product.value, lookupset(Fields!Subcat_ID.Value,Fields!Product_ID.Value,Fields!Product.Value,"dsMain")

Related

SSRS report pass multiple VALUES to drill through report parameter

I created a report with 5 fields in a hierarchical order:
Order Date
Time of Day (AM/PM)
Parent Name (aka customer)
Product Line
BIC Part Number (aka Item)
Each field expands down to the next level, so order date expands to time of day, etc.
I want to create a drill through report so that the user can click on each level of the hierarchy and see the detail.
This works fine at the lowest level - Item - because only 1 values from each field has to be passed to the drill through report parameter. However, when I try, for example, to drill through based on Product Line, there will usually be 3 or 4 Items within this product line. In the Go To action, I have the drill through parameter "bic_part" set to the main report FIELD value "BIC Part Number".
I have the tablix on the drill through report set where "BIC Part Number" IN [#bic_part].
I just want to be clear, I am passing a set of report field values to the drill through report parameter, not parameter to parameter.
I have tried using expressions with =Split(Join(field value),","),",") and all variations on that. I can't seem to get the child report filters to accept multiple values from the BIC Part Number field from the parent report.
I also tried omitting the BIC Part Number value in the go to report section, but it would not let me.
All of the parameters in the child report are set to accept multiple values. My data source for both reports is the same stored proc, so I can add a query filter. I would appreciate any help.
I think each sub report link needs to be slightly different.
In the subreport, each parameter needs to accept null and your query needs to look for
(FieldName = #FieldNameParameter or #FieldNameParameter is null)
This will allow you to pass the lowest possible solid value, then null for all child values.
If we're looking at the Parent_Number level, on that subreport link you would pass Fields!Parent_Number.Value and then Nothing for each of the lower parameters (Product_Line, BIC_Part_Number).
This will allow you to filter on the lower common denominator in your sub report - Part_Number for this link, Product_Line for the next one down, etc.
I've used this logic in reports before, so it does work. Let me know if my explanation needs clarification - it's Friday afternoon..

passing multi valued parameter to sub report in SSRS

I have built a report which lists all the loans that are available for a specified date range(below is the screen shot of the report).There are a number of filters and data logic involved in pulling this report.The numbers high-lighted in yellow are the total no of loans in each bucket.When the user clicks on the totals I need to open a sub report with all loans falling in that bucket.I have created a sub report which accepts loan numbers as a parameter and set it to allow multiple values. Set the text box properties on the main report to go to the subreport when clicked on the totals.But I am unaware of how to pass multiple loan numbers from the main report to sub report.
Any help would be much appreciated.
What I am currently doing is passing required filters/details to the sub report , so that it can reevaluate. Reevaluating the report takes a lot of of time as there are many condition that need to be evaluated. It would be quicker if I could send the list of loan numbers.
Rather than pass a list, you'll need to pass in enough detail so your subreport can reevaluate and come back with the same set of loans.
This might be a little simplistic but base on your screen show you would pass in the Date Range column value. I'll assume for now (as I have no more information on your data) that the column is just a text column as it appears above.
So you sub-report would accept a daterange parameter and you would pass this as =Fields!DateRange.Value. The subreport would then do something like..
SELECT * FROM myLoansTable WHERE DateRange = #daterange
If there are more parameters set in the main report, you may need to pass those too so your subreport gives the same set of loans as displayed in the main report.
Hope that makes sense.

SSRS 2012 Parameter settings

I am creating a report with columns say A,B,C,D,E. I am setting up a drill down on the column A that fetches one more report with Columns
G,H,I,J. The values for the columns G,H,I are from taken the columns A B C. For the column J,I need to pass a parameter explicitly(not from the source report). I set that parameter in
the properties section -> Available Values and mentioned the values. I ran the main report and get the following error
The Parameter J is a missing value
I am pretty much new to the SSRS projects and would be great if I could any assistance on this
It sounds like you are putting parameter J in the wrong place. It doesn't go in the Parameters collection for the main report but in the parameters that are passed to the sub-report.
Right-click the cell with the drill-down and select Text Box Properties.... Choose Action from the left-hand menu and it will show the drill-down report. Under this it says Use these parameters to run the report:
Add the parameters of the sub-report and the values you are passing. You can use an expression to provide the value for parameter J.

According to parameter different report should open on Image(button) click in ssrs 2005

I am working on SSRS 2005 and creating report, The report has two parameter one is date and other is Department. Department parameter may be null.There is also image(button) Graphical View.
Now condition is....
When I pass only date and click on the button then
"AllDepartmentReport" Should open.
When I pass date and department then only "DepartmentWiseReport" should open.
Create an expression for the action of your image.
Something like:
=IIF(
ISNOTHING(Parameters!Department.Value),
"AllDepartmentReport",
"DepartmentWiseReport"
)

Display a new page for each driver in the main report when using multi-value parameter and subr

I am working on a report that uses multiple sub-reports. I have two parameters: t_driver_pk and BatchID for the report. I have been able to display the data for each driver on a new page in the subreport using page break and repeat header options (all the subreports have been grouped by t_driver_pk). But, then when I go to main report and run it selecting multiple drivers on t_driver_pk parameter. I am getting a single report that combines the data for all those driver. Essentially, I would like to have it displayed as following:
Parameters:
**t_driver_pk**: 5000,4500 BatchID:610
FirstDriver
Subreport1
Subreport2
Subreport3
Subreport4
Second Driver
Subreport1
Subreport2
Subreport3
Subreport4
Any help would be greatly appreciated. Thanks in advance!
Have you tried adding a Dataset to the report that is driven by the selected t_driver_pk values (i.e. if 5000 and 4500 are selected in the parameter then the new dataset returns the same values).
You should be able to use this dataset with a List data region, which you can insert your subreports into and then pass the current value of t_driver_pk from the new dataset to the subreports. That should repeat them for each value of t_driver_pk.