USERID function
Returns a character string representing the user ID of the current user.
Syntax
logical-dbname
The logical name of the database from which you want to retrieve the user ID. The logical database name must be a character string enclosed in quotes, or a character expression. If you do not specify this argument, the Compiler inserts the name of the database that is connected when the procedure is compiled. If you omit this argument and more than one database is connected, ABL returns a compiler error.ExampleThis one-line procedure displays the current user ID for the database with the DICTDB alias:
Notes
- Use the Userid (-U) parameter together with the Password (-P) parameter. The AVM checks the _User table for the user ID supplied with the -U parameter. When it finds that user ID, it compares the password supplied with the -P parameter with the password in the _User table. If the two passwords match, the AVM assigns that user ID to the ABL session.
- When using the USERID function, ABL returns a compiler error under the following conditions:
- When specifying the
logical-dbname
argument, you must provide the name of the logical database, not the physical database.- Every user who enters ABL is given an initial user ID. Table 65 shows how ABL determines a user’s initial user ID on UNIX.
Table 66 shows how ABL determines a user’s initial user ID in Windows.
- After ABL starts running, you can use the SETUSERID function to change the current user ID.
- ABL user IDs are case sensitive.
- See OpenEdge Development: Programming Interfaces and OpenEdge Data Management: Database Administration for more information on security.
See also
OpenEdge Release 10.2B
|