Prev | Current Page 825 | Next

Richard Niemiec

"Oracle Database 10g Performance Tuning Tips & Techniques"

Each partition is stored in its
own tablespace??”either PRD01, PRD02, PRD03, or PRD04.
You use maxvalue to catch any date values after 12/1/2007; if you had specified to_date(???200
80301??™,??™YYYYMMDD??™) as the upper bound for the fourth partition, then any attempt to insert rows
with date values after 2/28/2008 would fail. On the other hand, any rows inserted with dates
before 6/1/2007 would end up in partition CAT_REQ_SPR_2007, even rows with a catalog
request date of 10/1/1963! This is one case where the front-end application may provide some
assistance in data verification, both at the low end and the high end of the date range.
The data dictionary view DBA_TAB_PARTITIONS shows you the partition components of the
CAT_REQ table, as you can see in the following query:
SQL> select table_owner, table_name,
2 partition_name, tablespace_name
3 from dba_tab_partitions
?– 
?– 
?– 
Chapter 16: Managing Large Databases 559
4 where table_name = 'CAT_REQ';
TABLE_OWNER TABLE_NAME PARTITION_NAME TABLESPACE_NAME
--------------- ------------ -------------------- ---------------
OE CAT_REQ CAT_REQ_FAL_2007 PRD03
OE CAT_REQ CAT_REQ_SPR_2007 PRD01
OE CAT_REQ CAT_REQ_SUM_2007 PRD02
OE CAT_REQ CAT_REQ_WIN_2008 PRD04
4 rows selected.
Finding out the dates used in the values less than clause when the partitioned table was
created can be done in the same data dictionary view, as you can see in the following query:
SQL> select partition_name, high_value
2 from dba_tab_partitions
3 where table_name = 'CAT_REQ';
PARTITION_NAME HIGH_VALUE
-------------------- ----------------------------------------
CAT_REQ_FAL_2007 TO_DATE(' 2007-12-01 00:00:00', 'SYYYY-M
M-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIA
N')
CAT_REQ_SPR_2007 TO_DATE(' 2007-06-01 00:00:00', 'SYYYY-M
M-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIA
N')
CAT_REQ_SUM_2007 TO_DATE(' 2007-09-01 00:00:00', 'SYYYY-M
M-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIA
N')
CAT_REQ_WIN_2008 MAXVALUE
4 rows selected.


Pages:
813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837
mapa wiezien Opinie Uwodzenie serwery kadencja4