Authorization

For any form of a query, the privileges held by the authorization ID of the statement must include at least one of the following:

  • For each table or view identified in the statement,
    • The SELECT privilege on the table or view, and
    • The system authority *EXECUTE on the library containing the table or view
  • Start of changeDatabase administrator authorityEnd of change
If a query includes a user-defined function, the privileges held by the authorization ID of the statement must include at least one of the following:
  • For each user-defined function identified in the statement:
    • The EXECUTE privilege on the function
  • Start of changeDatabase administrator authorityEnd of change

For information about the system authorities corresponding to SQL privileges, see Corresponding System Authorities When Checking Privileges to a Table or View or Corresponding System Authorities When Checking Privileges to a Function or Procedure.

Start of changeIf the query references a table that contains active row or column access control and row permissions or column masks are defined for the table, the authorization ID of the statement does not need authority to reference objects that are specified in the definitions of those row permissions or column masks.End of change