Re: Get partition name for specific date
Posted by:
Rick James
Date: October 09, 2012 09:21AM
It's a bit kludgy, but this seems feasible:
EXPLAIN PARTITIONS SELECT * FROM tbl WHERE valid_at = '2012-09-28';
Then parse that to get the partition name.
Have you checked your SELECTs to see if they are doing "pruning"?
You are assuming there is only one day's worth of data in that partition. Because of that risky assumption, I prefer partitioning BY RANGE and do a DROP and REORGANIZE every day to shift the partitions.
Also, I find 92 to be a large number of partitions; I would go with weekly, not daily, for a quarter's worth of data.
Subject
Views
Written By
Posted
3159
October 08, 2012 12:48PM
Re: Get partition name for specific date
1791
October 09, 2012 09:21AM
1672
October 10, 2012 03:18AM
1800
October 11, 2012 07:12PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.