Previous | Contents | Index |
Converts an alphanumeric identifier to its integer equivalent, or converts an integer identifier to its alphanumeric equivalent. An identifier is a name or number that identifies a category of users. The system uses identifiers to determine a user's access to a resource.
F$IDENTIFIER (identifier,conversion-type)
identifier
Specifies the identifier to be converted. Specify the identifier as an integer expression if you are converting an integer to a name. Specify the identifier as a character string expression if you are converting a name to an integer.Any identifier holding the Name Hidden attribute will cause the F$IDENTIFIER to return an error when you do not hold the identifier in question or do not have access to the rights database. For further information on the attribute, see the HP OpenVMS Guide to System Security.
conversion-type
Indicates the type of conversion to be performed. If the identifier argument is alphanumeric, specify the conversion-type argument as a character string containing "NAME_TO_NUMBER". If the identifier argument is numeric, specify the conversion-type argument as a character string containing "NUMBER_TO_NAME".
#1 |
---|
$ UIC_INT= F$IDENTIFIER("SLOANE","NAME_TO_NUMBER") $ SHOW SYMBOL UIC_INT UIC_INT = 15728665 Hex = 00F00019 Octal = 00074000031 $ UIC = F$FAO("!%U",UIC_INT) $ SHOW SYMBOL UIC UIC = [360,031] |
This example uses the F$IDENTIFIER to convert the member identifier from the UIC [MANAGERS,SLOANE] to an integer. The F$IDENTIFIER function shows that the member identifier SLOANE is equivalent to the integer 15728665. Note that you must specify the identifier SLOANE using uppercase letters.
To convert this octal number to a standard numeric user identification code (UIC), use the F$FAO function with the !%U directive. (This directive converts a longword to a UIC in named format.) In this example, the member identifier SLOANE is equivalent to the numeric UIC [360,031].
#2 |
---|
$ UIC_INT = (%O31 + (%X10000 * %O360)) $ UIC_NAME = F$IDENTIFIER(UIC_INT,"NUMBER_TO_NAME") $ SHOW SYMBOL UIC_NAME UIC_NAME = "ODONNELL" |
This example obtains the alphanumeric identifier associated with the numeric UIC [360,031]. First, you must obtain the longword integer that corresponds to the UIC [360,031]. To do this, place the member number into the low-order word. Place the group number into the high-order word. Next, use the F$IDENTIFIER function to return the named identifier associated with the integer.
Previous | Next | Contents | Index |