  END P_DELETE_CACHE @
 
 /**
- * Activates the cache.
+ * Activates the cache. Cleans any previous value on the cache.
  */
 ALTER MODULE LOGGER ADD
   PROCEDURE ACTIVATE_CACHE (

 P_DEA_CACHE: BEGIN
  DECLARE VAL ANCHOR LOGDATA.CONFIGURATION.VALUE;

  -- Check that the configuration variable is false
  SELECT VALUE INTO VAL
    FROM LOGDATA.CONFIGURATION
	WHERE KEY = INTERNAL_CACHE;
  IF (VAL = 'true') THEN
   SIGNAL SQLSTATE VALUE 'LG002'
     SET MESSAGE_TEXT = 'Invalid configuration state';
  END IF;
  SET CACHE = FALSE;
  SET LOADED = FALSE;
  -- Cleans the cache

 * Unload configuration. This is useful for tests, but it should not called
 * used in production.
 */
ALTER MODULE LOGGER ADD
  PROCEDURE UNLOAD_CONF (
  )
  LANGUAGE SQL
