  * After validating the level, it checks all appenders to see in which it has to
  * log the message.
  *
- * IN LOGGER_ID
+ * IN LOG_ID
  *   This is the associated logger of the provided message. Default logger is
  *   ROOT, that is 0.
  * IN LEVEL_ID

    -- Checks the values
    CASE APPENDER_ID
      WHEN 1 THEN -- Pure SQL PL, writes in table.
        CALL LOG_SQL(LOGGER_ID, LEVEL_ID, MESSAGE, CONFIGURATION);
      WHEN 2 THEN -- Writes in the db2diag.log file via a function.
        CALL LOG_DB2DIAG(LOGGER_ID, LEVEL_ID, MESSAGE, CONFIGURATION);
      WHEN 3 THEN -- Writes in a file (Not available in express-c edition.)
        CALL LOG_UTL_FILE(LOGGER_ID, LEVEL_ID, MESSAGE, CONFIGURATION);
      WHEN 4 THEN -- Sends the log to the DB2LOGGER in C.
        CALL LOG_DB2LOGGER(LOGGER_ID, LEVEL_ID, MESSAGE, CONFIGURATION);
      WHEN 5 THEN -- Sends the log to Java, and takes the configuration there.
        CALL LOG_JAVA(LOGGER_ID, LEVEL_ID, MESSAGE, CONFIGURATION);
      ELSE -- By default writes in the table.
        CALL LOG_SQL(LOGGER_ID, LEVEL_ID, MESSAGE, CONFIGURATION);
    END CASE;
    FETCH APPENDERS INTO APPENDER_ID, CONFIGURATION;
   END WHILE;
   CLOSE APPENDERS;
  END IF;
END P_LOG @


 */
ALTER MODULE LOGGER ADD 
  PROCEDURE LOG (
  IN LOG_ID ANCHOR CONF_LOGGERS.LOGGER_ID DEFAULT 0,
  IN LEVEL_ID ANCHOR LEVELS.LEVEL_ID DEFAULT 3,
  IN MESSAGE ANCHOR LOGS.MESSAGE
  )
