As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at firstname.lastname@example.org and provide your corporate email address, company, and name.
Connect to myibi
posted October 09, 2013 04:27 PM
I am trying to get the userid of the user logged in to Webfocus, but what I am doing is always returning 'wfadmi'. (No, that's not my userid.) Is there a different way to do this?
-SET &USR = GETUSER(USERID);
-TYPE &USR This message has been edited. Last edited by: <Kathryn Henning>, October 29, 2013 10:29 AM WebFOCUS 7.6.9 Windows all output (Excel, HTML, PDF)
posted October 09, 2013 05:08 PM
WebFOCUS 7.6.9 Windows all output (Excel, HTML, PDF)
posted October 09, 2013 05:19 PM
What Waz is asking has great relevance as it all depends on your particular infrastructure and WebFOCUS components involved.
In my case for instance, we use LDAP authentication to Active Directory on both WebFOCUS Reporting Server and Client.
On the WF Client's Custom Settings (accessible via the WebFOCUS Administration Console > Configuration > Custom Settings), we have the following:
That allows us to use &IBIMR_user anywhere in our code to determine who is connected.
Being usually on the paranoid side, I prefer to test for the existence of that variable first, falling back on GETUSER() otherwise. This is what I use in the "common" portion of my procedures:
-* Determine connected user ID
-IF &IBIMR_user.EXISTS THEN GOTO :_IBIMR_user;
-SET &IBIMR_user = ' ';
-SET &I_USER_ID = IF &IBIMR_user EQ '' OR ' ' OR '.' THEN GETUSER('A80') ELSE &IBIMR_user;
-SET &I_USER_ID = TRUNCATE(&I_USER_ID);
-TYPE Welcome &I_USER_ID !
That way, I can "trust" that &I_USER_ID (my own internal variable) has a valid content I can use for logging or any security-related purposes.
Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2 Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
posted October 10, 2013 08:17 AM
I think you want the connect user.
-SET &UID = CNCTUSR('A15');
WF 7.7.05 HP-UX - Reporting Server, Windows 2008 - Client, MSSQL 2008, FOCUS Databases, Flat Files HTML, Excel, PDF
Posts: | Location: 149 Dallas, TX | Registered: June 08, 2007 Read-Only Topic
Copyright © 1996-2020 Information Builders