Problem solve Get help with specific problems with your technologies, process and projects.

Who am I signed on as?

Wondering how to find out who you are signed on as on a particular workstation? This tip will show you how it's done.

You Can View User Feedback To This Tip

If you work for a company that has multiple AS/400's and you use multiple user-ID's and workstations to perform various tasks, it is easy to lose track of whom you are signed on as on a particular workstation. I have created a simple command called 'WhoAmI' that displays:

1. The user-ID
2. The system (network) I am logged on to
3. Number of interactive jobs on a session and which user-ID is logged on at each of the interactive jobs
4. For 2 interactive jobs in a session, it will also indicate which interactive job is currently active.

1. Create and compile a CLP source program called WHOAMI
PGM
DSPWSUSR
ENDPGM

2. Create command source called WHOAMI
CMD PROMPT('Who am I?')

3. Create the command WHOAMI
CRTCMD CMD(WHOAMI) PGM(WHOAMI)

4. Create the object in QGPL and set the object authority appropriately to allow everyone to use the command. To use, type whoami on a command line and press ENTER.

USER FEEDBACK TO THIS TIP

  • There's an even easier way to know who you're signed on as and what system you're signed on to,and you don't have to code a thing.....System request 3 and look at the top of the screen.

    — D. Jorgensen

  • This was last published in July 2001

    Dig Deeper on RPG iSeries programming

    Start the conversation

    Send me notifications when other members comment.

    Please create a username to comment.

    -ADS BY GOOGLE

    SearchDataCenter

    Close