Logger 3.1.0: log_apex_items Enhancements

logger.log_apex_items is a procedure to store all the APEX items for a user's current session. When called, a parent entry is stored in the usual logger_logs table and all the APEX items and thier values are stored in logger_logs_apex_items.

Previously logger.log_apex_items only had two parameters: p_text and p_scope. These parameters are common with all the other main Logger procedures. Aside from the new p_level parameter, it now takes in two additional parameters to give you more control of what is logged:

  • p_item_type: This determines which APEX items will actually be stored in logger.log_apex_items. Valid values are:
    • logger.g_apex_item_type_all: For both application and page level items.
    • logger.g_apex_item_type_app: For application items only.
    • logger.g_apex_item_type_page: For page items only.
    • <page number>: Pass in a page number and only items on that page will be logged.
  • p_log_null_items: If set to true, items will still be logged even if their values are null. If set to false, only non null values will be logged.

Both of the new parameters help reduce the amount of APEX items that are logged. This can be very useful in large applications where you may only need to see a subset of all the items when debugging you application.