Joel

There is a C/C++ function that can be used to check existence and/or authorization. It is access(). It is used in our CHKOBJIFS command that is part of the WebDocs product you have. That command sends a monitorable message that report the results.

That command is usable for anything, including library objects - just use the path naming for library objects.

You can see what the messages are by just running the command in CALL QCMD with detailed messages turned on.

If you can monitor for messages in COBOL, it's an easy way to do what you want. If you still want to try out access(), It is exported by service program QP0LLIB1. Documentation at

http://publib.boulder.ibm.com/infocenter/iseries/v6r1m0/topic/apis/access.htm

I suspect the QLICKOBJ program is a system level - DSPOBJD should give you more information - DSPOBJAUT may also help - I'm not on a system at the moment, so can't tell.

HTH
Vern

On 4/25/2012 11:04 AM, Stone, Joel wrote:
Is it safe to CALL QLICKOBJ as described in the CHKOBJ command info below?

Or could IBM change the pgm name or parms called by CHKOBJ command in future releases?


If I try "CALL QLICKOBJ", I find that I don't have authority to call it.

How can I use CHKOBJ to call QLICKOBJ, but don't have authority to call it directly? What allows me to run QLICKOBJ only when going thru CHKOBJ command?

Is there a better method for checking if object exists?


Display Object Authority

Object . . . . . . . : QLICKOBJ Owner . . . . . . . : QSYS
Library . . . . . : QSYS Primary group . . . : *NONE
Object type . . . . : *PGM ASP device . . . . . : *SYSBAS

Object secured by authorization list . . . . . . . . . . . . : *NONE

Object
User Group Authority
*PUBLIC *EXCLUDE

Thanks







Display Command Information

Command . . . . . . . : CHKOBJ Library . . . . . . . : QSYS

Program to process command . . . . . . : QLICKOBJ
Library . . . . . . . . . . . . . . : QSYS
State used to call program . . . . . : *SYSTEM
Source file . . . . . . . . . . . . . : S000043355
Library . . . . . . . . . . . . . . : QTEMP
Source file member . . . . . . . . . . : CHKOBJ
Validity checking program . . . . . . : *NONE
Mode(s) in which valid . . . . . . . . : *PROD
*DEBUG
*SERVICE
Where allowed to run . . . . . . . . . : *IMOD *BMOD *IREXX
*BREXX *BPGM *IPGM
*EXEC *INTERACT *BATCH

______________________________________________________________________
This outbound email has been scanned for all viruses by the MessageLabs Skyscan service.
For more information please visit http://www.symanteccloud.com
______________________________________________________________________

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].