DB2 graphic QMF Version 8

Global variables in procedures

  1. Create or open a procedure.
  2. Type global information in the procedure, such as:
    SET GLOBAL(MY_GLOBAL=20
  3. Optional: Add multiple variables, such as a string of variables:
    SET GLOBAL(MY_GLOBAL=20,START_DATE=&DATE,DEPARTMENT=&DEPT

    This example lists each variable and uses the SET GLOBAL command only for the first time:

    SET GLOBAL(MY_GLOBAL=20,
    START_DATE=&DATE,
      +DEPARTMENT=&DEPT
  4. Type the following command as the last line in the procedure:
    RESET GLOBAL ALL
    Note:
    This command resets the user variables.


Go to the previous page Go to the next page

Downloads | Library | Support | Support Policy | Terms of use | Feedback
Copyright IBM Corporation 1982,2004 Copyright IBM Corporation 1982, 2004
timestamp Last updated: March, 2004