Declaring keywords as names for variables in UDRs

If you use some keywords as identifiers for variables in a user-defined routine (UDR), you can create ambiguous syntax:

The following constant expressions and other SQL keywords might produce unexpected results as variable names.
  • CURRENT
  • CURRENT_ROLE
  • CURRENT_USER
  • DATETIME
  • DEFAULT_ROLE
  • GLOBAL
  • INTERVAL
  • NULL
  • OFF
  • OUT
  • PROCEDURE
  • SELECT
  • SYSDATE
  • TODAY
  • UNITS
  • USER