QsyRemoveValidationLstEntry()--Remove Validation List Entry API


  Syntax
 #include <qsyvldl.h>

 int QsyRemoveValidationLstEntry
        (Qsy_Qual_Name_T        *Validation_Lst,
         Qsy_Entry_ID_Info_T    *Entry_ID);


  Service Program Name: QSYVLDL

  Default Public Authority: *USE

  Threadsafe: Yes

The QsyRemoveValidationLstEntry() function removes an entry from a validation list object. To identify an entry to be removed, there must be an exact match in the entry for the value that is specified in the Entry_ID parameter and the length of the entry ID. For example, an entry ID value of "SMITH" with a length of 5 would not remove an entry where the entry ID is "SMITH " and the length is 7.

Authorities

Validation List Object
*USE and *DLT
Validation List Object Library
*EXECUTE

Parameters

Validation_Lst
(Input)

A pointer to the qualified object name of the validation list that contains the entry to remove. The first 10 characters specify the validation list name, and the second 10 characters specify the library. You can use these special values for the library name:

*CURLIB The current library is used to locate the validation list. If there is no current library, QGPL (general purpose library) is used.
*LIBL The library list is used to locate the validation list.


Entry_ID
(Input)

A pointer to the entry ID information. Qsy_Entry_ID_Info_T structure is as follows:

int Entry_ID_Len The number of bytes of data that is provided as the entry ID. Possible values are from 1 through 100.
unsigned int Entry_ID_CCSID An integer that represents the CCSID for the entry ID. Valid CCSID values are in the range 0 through 65535. This value is not used to remove the entry.
unsigned char Entry_ID[100] The data that is used to identify this entry in the validation list.

Return Value

0 QsyRemoveValidationLstEntry() was successful.
-1 QsyRemoveValidationLstEntry() was not successful.

The errno global variable is set to indicate the error.


Error Conditions

If QsyRemoveValidationLstEntry() is not successful, errno indicates one of the following errors:

3401 [EACCES]

The current user does not have *USE and *DLT authorities to the validation list object, or does not have *EXECUTE authority to the validation list object library.

3406 [EAGAIN]

The validation list object is currently locked by another process.

3484 [EDAMAGE]

The validation list object is damaged.

3021 [EINVAL]

Parameter value is not valid.

3025 [ENOENT]

The validation list object was not found.

3026 [ENOREC]

Specified entry does not exist.

3474 [EUNKNOWN]

Unknown system state. Check the job log for a CPF9872 message.


Example

The following example removes an entry for a user named FRED in the validation list object WEBUSRS.

Note: By using the code examples, you agree to the terms of the Code license and disclaimer information.

#include <qsyvldl.h>

main()
{
  #define VLD_LST  "WEBUSRS   WEBLIB    "
  Qsy_Entry_ID_Info_T    entry_info;

  entry_info.Entry_ID_Len = 4;
  strncpy(entry_info.Entry_ID,"FRED",entry_info.Entry_ID_Len);

  if (0 != QsyRemoveValidationLstEntry(
                       (Qsy_Qual_Name_T *)&VLD_LST,
                       &entry_info))
     perror("QsyRemoveValidationLstEntry()");

}


API introduced: V4R1

[ Back to top | Security APIs | APIs by category ]