Re: export/import partition statistics

  • From: "LS Cheng" <exriscer@xxxxxxxxx>
  • To: ax.mount@xxxxxxxxx
  • Date: Tue, 18 Sep 2007 16:42:40 +0200

Hi

You have to update TABSTATS.C2 with new partition name then import

thanks

--
LSC

On 9/18/07, amonte <ax.mount@xxxxxxxxx> wrote:
>
> Hi
>
> Is it possible export a partition statistics and import to another
> partiton (in the same table)? I have tried it but doesnt seem to work in
> 9.2.0.8, or may be never worked but to be honest have not tried before.
>
>
> select table_name, partition_name, num_Rows from user_tab_partitions;
>
> TABLE_NAME                     PARTITION_NAME                   NUM_ROWS
> ------------------------------ ------------------------------ ----------
> GTADEPT                       GTADEPT1                                0
> GTADEPT                       GTADEPT2                                0
> GTADEPT                       GTADEPT3                                1
> GTADEPT                       GTADEPT4                                6
> GTADEPT                       GTADEPT5                                4
> GTADEPT                       GTADEPT6                                6
> GTADEPT                       GTADEPT7                                0
> GTADEPT                       GTADEPT8                                0
> GTADEPT                       GTADEPT9                                0
>
>
> exec dbms_stats.export_table_stats('SCOTT', 'GTADEPT', 'GTADEPT5',
> 'TABSTATS')
>
> exec dbms_stats.import_table_stats('SCOTT', 'GTADEPT', 'GTADEPT9',
> 'TABSTATS')
>
> select table_name, partition_name, num_Rows from user_tab_partitions;
>
> TABLE_NAME                     PARTITION_NAME                   NUM_ROWS
> ------------------------------ ------------------------------ ----------
> GTADEPT                       GTADEPT1                                0
> GTADEPT                       GTADEPT2                                0
> GTADEPT                       GTADEPT3                                1
> GTADEPT                       GTADEPT4                                6
> GTADEPT                       GTADEPT5                                4
> GTADEPT                       GTADEPT6                                6
> GTADEPT                       GTADEPT7                                0
> GTADEPT                       GTADEPT8                                0
> GTADEPT                       GTADEPT9                                0
>
>
> TIA
>
>
>

Other related posts: