Quantcast
Channel: dBforums – Everything on Databases, Design, Developers and Administrators
Viewing all articles
Browse latest Browse all 13329

db2 range partition for tables

$
0
0
Hi all,

In our setup db2 V9.7 with fixpack 4

Question with partitioning the tables.

Planning to do the Range partition for the tables. Using timestamp column.

MIN DATE MAX DATE
17-05-2004 14-05-2013

DDL:

CREATE TABLE "db2DWH".TIS_DW_METRIC_VOL1 (
"SITE_ID" INTEGER NOT NULL,
"ITM_ID" INTEGER NOT NULL,
"SRVY_TMS" TIMESTAMP NOT NULL,
"TFM_ID" INTEGER NOT NULL,
"ORGN_LEG_NBR" SMALLINT NOT NULL,
"DEST_LEG_NBR" SMALLINT NOT NULL,
"DTCTR_ID" INTEGER NOT NULL
)
DATA CAPTURE NONE
IN "METRIC_VOL_TAB"
PARTITION BY RANGE ("SRVY_TMS") (STARTING "17/05/2004 00:00:00" ENDING "14/05/2013 00:00:00" EVERY 1 YEAR);
COMPRESS NO;

When i executed I am getting the below error:
An unexpected token ""17/05/2004 00:00:00" ENDING "14/05/2013 " was found following "SRVY_TMS") (STARTING". )

How to do the range partition by using the timestamp column?

Thanks
laxman.

Viewing all articles
Browse latest Browse all 13329

Trending Articles