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!

Help with user list

Status
Not open for further replies.

RedHeadedStepITChild

IS-IT--Management
May 31, 2007
46
0
0
US
I hope this message finds everyone well.

I think the answer to my question will be pretty simple, however I cannot seem to find the answer anywhere. Is there a command I can execute to dump a list of enabeled users to a printer? I've tried coming up with a CL program, alas, I'm a nOOb and screwed that all up :)

Any help would be much appreciated.
 
Red,

Use the command DSPUSRPRF and output it to a *OUTFILE. There's a field, UPSTAT, in the file that indicates if a user is enabled. UPSTAT = '*ENABLED' indicates an enabled user. You can run a query against the file and print a list.

DSPUSRPRF USRPRF(*ALL) OUTPUT(*OUTFILE) OUTFILE(Lib/File)

[rockband]
 
Great! I was trying to DSPUSRPRF USRPRF(*ALL) STATUS(*ENABLED) but the system was yelling that it didn't like that :)

If you could help me take this one step further, it would be much appreciated. Is there a command that will tell me when the last time an account was logged into? That way, all I can check all of the *DISABLED accounts to see how long ago the accounts were logged into, to decide whether to delete the profile or not.
 
Run a query over the output file. All of these fields are character fields:

Code:
Previous sign-on century:   UPPSOC (0=1900-1999; 1=2000-2099, etc.)
Previous sign-on date:      UPPSOD (YYMMDD format)
Previous sign-on time:      UPPSOT (HHMMSS)
Status:                     UPSTAT

UPSTAT will be '*ENABLED' or '*DISABLED'.

I'm not

Nullum gratuitum prandium.
--Sleipinir214

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top