Re: Analyze only latest partition

2001-11-28 Thread Connor McDonald
declare pname varchar2(100); begin select partition_name into pname from user_tab_partitions where table_name = ... and partition_id = ( select max(partition_id) from user_tab_partitions where table_name = ... ); execute immediate 'analyze table ... partition

RE: Analyze only latest partition

2001-11-28 Thread Tatireddy, Shrinivas (MED, Keane)
Hi Connor Thanq for responding. In dba_tab_partitions there is no such column like partition_id, and I would like to generate a list at schema level for each table. That means, this script should capture the latest (last) partitions for each table (if it is partitioned) for a given schema.

RE: Analyze only latest partition

2001-11-28 Thread Nirmal Kumar Muthu Kumaran
Title: RE: Analyze only latest partition Hi Why not you can try with partition related dictionary views: Here is my query: [EMAIL PROTECTED] select table_name, partition_name, high_value, partition_position from dba_tab_partitions a where partition_position = (select max