how analyze statistics managed

i see analyze statistics on local temp table is supported in document.

will the statistic data purged while close the session which create the temp table?

 

the temp table is about 1M rows, created in a job whih called 1000 times a day. and data in the temp table is not static.

Comments

  • You need to use ON COMMIT PRESERVE ROWS option while creating the TEMP table. If the data is getting lost while you come out of the session, stats will also be lost.

  • That`s right, Can you provide any query that i can see the statistics data has gone after the session closed.
  • Hi, 

     

    The stats are only avilable in the running session for the local temp tbl.

    To see the stats status use this query:

    select projection_schema,anchor_table_name,projection_name,has_statistics 
    from projections where anchor_table_name='temp_tbl_name';

    If you drop the tbl / close the session no data will be returned by the statistics query.

     

     

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file