COGNOiSe.com - The IBM Cognos Community

IBM Cognos Analytics Platform => Cognos Analytics => Administration and Security => Topic started by: aojha on 12 Apr 2020 01:54:53 PM

Title: Set the commands - Open session commands
Post by: aojha on 12 Apr 2020 01:54:53 PM
How can I pass the current user name or ID to Open session command. In below example every time reports runs first it calls GiveDataAccess procedure, passes current user name as parameter values so that users data access is setup before report output comes. Is there any system variable which can be used in this store procedure call which can pass current login user name? or any other way to do this? Thank you. My database is Sybase IQ.

<commandBlock>
  <commands>
   <sqlCommand>
    <sql>EXECUTE dbo.GiveDataAccess('CurrentUserName')</sql>
   </sqlCommand>
  </commands>
</commandBlock>