Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Who is running the report - USERNAME

Status
Not open for further replies.

jackiev

MIS
Aug 16, 2000
56
US
I would like to inbed some minor security in a report to display different fields based on the name of the user who is running the report.
How do I extract the USERNAME?


example:
if USERNAME is 'staff' then display names & phone numbers
or if USERNAME is 'boss' then display names, phone & dollars.
 
You should be able to extract the information from the OS and session that your running. Put the resulting query into && variables, then you will be able to manipulate the resulting output.

Regards
Andrew
 
Depending on how the security has been setup.....and other changes may need to be applied....

You can use either GETUSER which is the ID that is being used on the system if the reporting server security is turned on

-SET &USERID = GETUSER('A8');

or if security is off, this will provide you with whatever was passed for IBIC_user

-SET &USERID = CNCTUSR('A8');
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top