Kernel 8.0 APIs Banner
Office of Information and Technology (OIT) Banner
[skip navigation]

$$ADD^XUSERNEW(): Add New User

Reference Type: Supported, Category: Signon/Security, ICR#: 10053

Description

The $$ADD^XUSERNEW extrinsic function adds new entries to the NEW PERSON (#200) file. After prompting for the user's name, it parses the input into its component parts, and then prompts for each name component separately, presenting the parsed input as defaults. It then prompts for the default identifiers for the NEW PERSON (#200) file entry in the following order:

  1. INITIALS (#1)

  2. SSN (#9)

  3. SEX (#4)

If the user of this function has the XUSPF200 security key, entry of the SSN is not required. The default identifiers can be locally modified by modifying the NEW PERSON IDENTIFIERS field in the KERNEL SYSTEM PARAMETERS (#8989.3) file.

To prompt for additional fields during this call, you pass a DR string containing the fields for which you wish to prompt as a parameter to this function. If the person adding the entry enters a caret (^) to exit out before filling in all the identifiers and requested fields, the entry is removed from the NEW PERSON (#200) file, and -1 is returned.

NOTE: This API was modified with Kernel Patch XU*8.0*134.

Format

  $$ADD^XUSERNEW([dr_string][,keys])

Input Parameters

dr_string:

(optional) Additional fields to ask when adding the new user, in the format for a DR string as used in a standard DIC call.

NOTE: For information about DIC, see the VA FileMan documentation.

keys:

(optional) A comma-delimited string of keys to assign to the newly created user.

Output

returns:

Returns a value similar in format to the value of Y returned from a standard DIC call:

  • -1—User neither existed nor could be added.

  • N^S—User already exists in the file; N is the internal number of the entry in the file, and S is the value of the .01 field for that entry.

  • N^S^1—N and S are defined as above, and the 1 indicates the user has just been added to the file.

NOTE: For information about DIC, see the VA FileMan documentation.

Example 1

To add a new user, asking default fields for new entry:

>S X=$$ADD^XUSERNEW

Enter NEW PERSON's name (Family,Given Middle Suffix): KRNUSER,TWO E
  Are you adding 'KRNUSER,TWO E' as a new NEW PERSON (the 1602ND)? No// Y <Enter> (Yes)
Checking SOUNDEX for matches.
No matches found.
Name components.
FAMILY (LAST) NAME: KRNUSER// <Enter> 
GIVEN (FIRST) NAME: TWO// <Enter>
MIDDLE NAME: E// <Enter>
SUFFIX: <Enter>
Now for the Identifiers.
INITIAL: TEK
SSN: 000222222
SEX: M <Enter>  MALE
>W X
1000118^KRNUSER,TWO E^1
>

Example 2

To add a new user, specifying a key to add:

>S X=$$ADD^XUSERNEW("","PROVIDER")

Example 3

To add a new user, specifying additional fields to ask, plus two keys to add:

>S X=$$ADD^XUSERNEW("5;13;53","PSMGR,PSNARC")