Suppose I've a table like this:
create table orders (
id int primary key generated always as
I want to store this table in a data tablespace and an index tablespace.
1) Should I create and use 2 large tablespaces (32k in size) for this table?
2) Appreciate if you could please also let me know the DDLs for the data and index tablespace.
NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
This topic has been locked.
1 reply Latest Post - 2012-09-07T16:36:00Z by MatthiasNicola
Pinned topic Storing XML data type in tablespaces !
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2012-09-07T16:36:00Z at 2012-09-07T16:36:00Z by MatthiasNicola
MatthiasNicola 120000E28R321 PostsACCEPTED ANSWER
Re: Storing XML data type in tablespaces !2012-09-07T16:36:00Z in response to Sambond007In most cases, using a large page size such as 16kb or 32kb is good for XML.
A discussion of XML storage options in DB2 -including sample DDL for table spaces and tables- can be found in Tip 2 and Tip 3 in this article:
15 best practices for pureXML performance in DB2
You may want to read through those examples first. Then let us know if you have additional questions.
To store indexes in a separate table space, use the "INDEX IN" clause of the CREATE TABLE statement as you would for tables without XML.