We help IT Professionals succeed at work.

Check out our new AWS podcast with Certified Expert, Phil Phillips! Listen to "How to Execute a Seamless AWS Migration" on EE or on your favorite podcast platform. Listen Now

x

using Hidden or Internal Parameters using SSRS 2008

Medium Priority
6,815 Views
Last Modified: 2012-08-14
Hi Experts,

              I have a requirement to show the drill through report in a new window(using SSRS 2008) . But I have a problem while implementing the Role Based Security. I am using a Parameter @Lan_ID and passing the build in field  value "User!UserID"  (to  capture the UserID of running the report ).
 I am using the above logic to  implement the Role based security.

Question :
 I am creating the parameter (@Lan_ID ) as "Hidden" in both the Main and the Drill through report  and Passing through the Query String URL from the Main Report  to the drill through report. It doesn't work and getting error message below when i click on the drill through column in  main report..

Error message : Parameter @Lan_ID  is missing a value .

When i change the parameter type to "Internal" , I am getting the error message  below.

Error :  Report Parameter is read only and cannot be modified.

Requirement : I want to hide the Lan_ID and pass from the Main report to Drill through report . I am not sure how to exactly achieve this without any error. I will really appreiate your help if you walk me through the steps and provide me a solution.


Kind Regards,

Sreekanth.
Comment
Watch Question

CERTIFIED EXPERT

Commented:
If I understand your question correctly, you need the user that is running the report as a parameter in you query so you can filter the data. What I did was
1. create an Internal parameter Lan_ID
2. set a default value for this parameter  with the expression: =User!UserID
Now I could use the @Lan_ID parameter in the Query of my Dataset.
You could use the same technique on the drill through report and then there is no need to pass the parameter. Or you could make the parameter on the drill through report hidden and pass it from the main report.

Author

Commented:
Hi Nicobo:

      Please correct me if I am wrong  (or) If i do not understand correctly .    
    Step 1:  I should create an Internal parameter Lan_ID in the Main report.  No  need to pass it to the drill through report.
  Ste p 2 : Pass the default value (=User!UserID) for the parameter Lan_ID in the Main report.
  Step 3 : Pass this Lan_ID parameter to the Stored Procedure which is bound to the Data Set of the Main Report. I am using an SP instead of a query.

  Step 4: Create the same Internal parameter Lan_ID  in the drill through report (and repeat Step 1, 2 ,3  for Drill through Report as well). But do not pass it from Main Report.

Regards,

Sreekanth.


CERTIFIED EXPERT
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
HI Nicobo :
                        
        I got you but please clarify whether I need to pass the parameter @Lan_ID from the Main Report to the Drill through report ???????
   
    I am passing all the parameters including @Lan_ID   through Query String URL from Main Report  to Drill through report  using (expression in Go to URL). Then I am passing this @Lan_ID  as an input parameter to the Stored Procedure  of the Drill through Report.

From your Comments above , you have mentioned that there is no need to pass the parameter @Lan_ID from Main Report to Drill Through Report.

If I do not pass this parameter then I would get an error message "@Lan_ID is missing a value" as  the
Stored Procedure of Drill through Report Expects this parameter.

So, I do not understand of how to pass this parameter from Main Report to Drill through Report.  
Please clarify on this and Please provide me a solution ...

Regards,

Sreekanth.
CERTIFIED EXPERT

Commented:
The user will be the same for the main and the Drill through report right? Which is the user running the report. If you use the technique described in comment 35455247 for both the main and the drill through report both reports will have the parameter @Lan_ID with the username as the value. Then there is no need to pass the parameter from the main to the drill through.
But I'm afraid we have some misunderstanding here. Can you upload the .rdl files for both the reports (rename them to xml for EE to accept them). That way we can make sure we are both talking about the same thing.

Author

Commented:
GOOD
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.