-
Determine the sampling method on table
Hi,
I have some tables for which stats are collected using block sampling.
Is there a data dictionary view that can tell me which tables stats have block sampling on them?
Thanks
Jay
-
-
I checked dba_tables before and could not find any column that suggested if the stats were collected using block or row sampling method.
Regards
Jay
-
Check SAMPLE_SIZE column in DBA_TABLES.
If you used DBMS_STATS package with " estimate_percent => xx " for row sampling instead of block sampling then you will see the value in SAMPLE_SIZE column.
Thanks,
Vijay Tummala
Try hard to get what you like OR you will be forced to like what you get.
-
the column Sample_size has a number value in it, how do we determine if it was gathered using row/block sampling?
-
well, I am not sure if we have any thumb rule to find that. My best guess is, you can only identify if you are sure that you have taken estimate_percent some value less than 100 like 30 or 40.
block_sample - NUM_ROWS = SAMPLE_SIZE
estimate_percent - NUM_ROWS != SAMPLE_SIZE
Some one please correct me if i am wrong.
Thanks,
Vijay Tummala
Try hard to get what you like OR you will be forced to like what you get.
-
I don't think Oracle keeps track on where you asked for blocks or rows sampling.
At the end of the line Oracle would sample rows, whatever random rows when you ask for rows or all the rows in a sample of blocks when you ask for blocks.
In general you are going to get a better random sample when asking for rows.
Pablo (Paul) Berzukov
Author of Understanding Database Administration available at amazon and other bookstores.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|