23.8 GET_TABLES_SUMMARY Function

This function gets a list of table/view names formatted as markdown or plain text.

Syntax

FUNCTION apex_db_dictionary.get_tables_summary (
    p_regex                  IN   VARCHAR2         DEFAULT NULL,
    p_owner                  IN   VARCHAR2         DEFAULT NULL,
    p_object_type            IN   VARCHAR2         DEFAULT NULL,
    p_include_comments       IN   BOOLEAN          DEFAULT TRUE,
    p_include_annotations    IN   BOOLEAN          DEFAULT TRUE,
    p_format                 IN   t_format_type    DEFAULT C_MARKDOWN )
    RETURN CLOB;

Parameters

Parameter Description
p_regex

Regular expression for object names.

p_owner

Owner of the tables/views (default current user).

p_object_type

TABLE or VIEW. The default NULL returns tables and views.

p_include_comments

Include table/view comments and comment-derived attributes (default TRUE).

p_include_annotations

Include table/view annotations (default TRUE).

p_format

c_markdown (default) or c_plain.

Returns

This function returns a CLOB summary for all matching tables/views, including requested annotations and/or comment-derived attributes.

Example 1

This example returns a CLOB containing a summary of all tables and views with names matching the regular expressing '^EMP_'.

declare
    l_summary clob; 
begin 
    l_summary := apex_db_dictionary.get_tables_summary( 
        p_regex => '^EMP_' ); 
end;

Example 2

This example returns a CLOB containing a summary of all tables with names matching the regular expression '^DB_' in plain text format.

declare
    l_summary clob; 
begin
    l_summary := apex_db_dictionary.get_tables_summary( 
        p_regex => '^DB_', 
        p_object_type => 'TABLE', 
        p_format => apex_db_dictionary.c_plain ); 
end;