Gather stats Query for Database,Schema and Table.

Gather Stats for a database :
——————————-

    exec dbms_stats.gather_database_stats(estimate_percent => 15, cascade => true);

Gather stats for a schema:
——————————–

    exec dbms_stats.gather_schema_stats(‘newuser’, estimate_percent => 15, cascade => true);

Gather stats for a table:
—————————-

    exec dbms_stats.gather_table_stats(‘newtab’, ‘newtab2’, estimate_percent => 15, cascade => true);

  • October 4, 2018 | 14 views
  • Comments