gather partition table in schema !
When there are not partition tables, I usually use bellow script to gather statistics of schema:
begin
dbms_stats.gather_schema_stats(
ownname => 'XBANK',
estimate_percent => dbms_stats.auto_sample_size,
method_opt => 'for all columns size auto',
cascade => true
);
end;
But now, I have some partition tables and can I use above script with granularity => 'DEFAULT' to gather statistics for schema XBANK ? It look like:
begin
dbms_stats.gather_schema_stats(
ownname => 'XBANK',
estimate_percent => dbms_stats.auto_sample_size,
method_opt => 'for all columns size auto',
granularity => 'DEFAULT'
cascade => true
);
end;
And last question: I was partitioning table A when a session sess_1 accessed and updated data of table A ==> Which errors that I can meet ?