Can't you use the return code from your CP QUERY? 0 = logged on, 3 = not in directory, 45 = in directory but not logged on...
-----Original Message----- From: The IBM z/VM Operating System [mailto:[EMAIL PROTECTED] Behalf Of Dave Hansen Sent: Thursday, October 25, 2007 9:16 AM To: IBMVM@LISTSERV.UARK.EDU Subject: How can I find if a user is defined in the directory (without looking!)? Hello, I have an EXEC that I wish to use to TRANS the console files from another userid for a given period of time. I would like to check if the userid given the EXEC actually exists. I looked at the CMS QUERY which does stack the results, but userid is not part of the CMS query. The CP Query does let me know about the user, but doesn't stack the results. The CP MSG (and SMSG) & IND USER don't care about the userid, and an invalid userid is always NOT LOGGED ON. It looks like I almost need to spool and close my console to get the results of my CP Query. I suppose I could just issue the TRANS against an invalid userid and let it fail. Any thoughts from the group? Thank you, Dave Hansen Sr. Systems Programmer Hennepin County __________________________________________________________________ << ella for Spam Control >> has removed VSE-List messages and set aside VM-List for me You can use it too - and it's FREE! http://www.ellaforspam.com