good morning
i work in a transportation corporation. the bus drivers belong
to branches and the buses enter the Garage for periodic treatments.
i want to drill through from a cube to a db target report .
if the current user is a Branch Manager i want to pass the branch
as a parameter to the target report and if the current user is a Garage Manager i want to pass the Garage as a parameter .
the target report is the same report for Branch Managers and for
Garage Managers.
With this you can find out the logged in user in Report Studio
#sq($account.personalInfo.userName)#
Thanks
prit
thanks for the answer.where do i have to locate this
macro function in the report ?
Sorry dear, I didn't read your post properly. Do you mean you want to Drill from CUBE to Report Studio report with passing parameter conditionally? If yes, then i am not sure how to get it done.
May be somebody else can guide you?
i want to drill from a cube report to a db report conditionally
depending on the current user and his security.
all in report studio 8.4.
help someone there ..
thanks ayelet
Ok.
Create a Data Item with below expression. It would give you the logged in User as said.
#sq($account.personalInfo.userName)#
Now Create another data item assuming [Data Item] returns 'Garage Manager' & 'Branch Manager' values.
[Data Item Test]:
Case #sq($account.personalInfo.userName)#
when 'Garage Manager' then [Data Item]
when 'Branch Manager' then [Data Item]
end
In your Source report, drill through definition, select the respective parameter that you defined in your target report. Source Type, select Data Item and associate the newly create [Data Item Test].
Hope this should resolve your issue.
Thanks
Prit