Directives 

DEF GID/UID

Define Group/User ID

Formats

1. Define Group ID:

DEF GID= groupID | groupname$ [,ERR=stmtref]

2. Define User ID:

DEF UID= userID | username$ [ LOCAL ] [,ERR=stmtref]

Where:

groupID

Numeric UNIX/Linux group ID number.

groupname$

UNIX/Linux group name.

userID

Numeric UNIX/Linux user ID number.

username$

UNIX/Linux user name or username to use when running in Windows.

stmtref

Program line number or statement label to which to transfer control.

Description

These directives allow you to override the effective UNIX/Linux user or group ID of a session if the operating system security allows it. If the value is *, the system reverts to original effective user or group ID.

For Windows, this directive merely changes the internal value returned in WHO or UID and the value stored in program headers when issuing a SAVE command. It is not validated by the operating system in any way.

The LOCAL option can be specified if the change of the  user ID is only an internal change to the value returned in UID/WHO and is not passed to or validated by the operating system.

Note:
Whether or not you can become a different user is governed by the operating system. If the operating system does not allow the change, an error will be returned.

(The LOCAL option was added in PxPlus v9.10, build 9201.)