Difference between revisions of "F$IDENTIFIER()"

From VSI OpenVMS Wiki
Jump to: navigation, search
(See also)
 
Line 34: Line 34:
 
* [[F$FAO()]]
 
* [[F$FAO()]]
 
* [[Lexical functions]]
 
* [[Lexical functions]]
 +
 +
[[Category: Lexical Functions]]

Latest revision as of 05:47, 15 January 2019

F$IDENTIFIER() 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 user or a category of users. The system uses identifiers to determine a user's access to a resource.

Format

F$IDENTIFIER(identifier,conversion-type)

Arguments

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 VSI OpenVMS Guide to System Security.

conversion-type

  • "NAME_TO_NUMBER": if the identifier argument is alphanumeric
  • "NUMBER_TO_NAME": if the identifier argument is numeric

Examples

$ 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]
$ UIC_INT = (%O31 + (%X10000 * %O360))
$ UIC_NAME = F$IDENTIFIER(UIC_INT,"NUMBER_TO_NAME")
$ SHOW SYMBOL UIC_NAME
UIC_NAME = "ODONNELL"

See also