Working with object ownership
You can change the ownership of an object in several ways.
- The Change Object Owner (CHGOBJOWN) command
- The Work with Objects by Owner (WRKOBJOWN) command
- The Change Owner (CHGOWN) command
The Work with Objects by Owner display shows all the objects owned by a profile. You can assign individual objects to a new owner. You can also change ownership for more than one object at a time by using the NEWOWN (new owner) parameter at the bottom of the display:
Work with Objects by Owner
User profile . . . . . . . : OLDOWNER
Type options, press Enter.
2=Edit authority 4=Delete 5=Display author
8=Display description 9=Change owner
ASP
Opt Object Library Type Attribute Device
COPGMMSG COPGMLIB *MSGQ *SYSBAS
9 CUSTMAS CUSTLIB *FILE *SYSBAS
9 CUSTMSGQ CUSTLIB *MSGQ *SYSBAS
ITEMMSGQ ITEMLIB *MSGQ *SYSBAS
Parameters or command
===> NEWOWN(OWNIC)
F3=Exit F4=Prompt F5=Refresh F9=Retrieve
F18=Bottom
When you change ownership using either method, you can choose to remove the previous owner's authority to the object. The default for the CUROWNAUT (current owner authority) parameter is *REVOKE.
- Object existence authority for the object
- *ALL authority or ownership, if the object is an authorization list
- Add authority for the new owner's user profile
- Delete authority for the present owner's user profile
You cannot delete a user profile that owns objects. The topic Deleting user profiles shows methods for handling owned objects when deleting a profile.
The Work with Objects by Owner display includes integrated file system objects. For these objects, the Object column on the display shows the first 18 characters of the path name. If the path name is longer than 18 characters, a greater than symbol (>) appears at the end of the path name. To see the absolute path name, place your cursor anywhere on the path name and press the F22 key.