Connecting Tech Pros Worldwide Help | Site Map
 
 
LinkBack Thread Tools Search this Thread
  #1  
Old November 12th, 2005, 09:00 AM
Markus Neifer
Guest
 
Posts: n/a
Default How many extents does a BLOB need?

Hi, could somebody please explain why the following statement consumes
six extents:

CREATE TABLE T1 (C1 INT, C2 BLOB(1K)) IN TS1

I see one extent for the extent map and one extend for data pages. How
many extents does this BLOB thing need?

Thanks in advance.

Regards,
Markus
  #2  
Old November 12th, 2005, 09:00 AM
Pierre Saint-Jacques
Guest
 
Posts: n/a
Default Re: How many extents does a BLOB need?

The other four extents are used by the tblspc itself.
One for the con tainer tag, one for header data, one for space map, one
for header object data. These four will always appear in each container.
From then on, each object will be created with two extents; one for the
extent map and one pre-allocated empty for the data to come in. As rows
grow, more extents are allocated and identified in the extent map which
will then grow new ones as needed.

HTH, Pierre.

Markus Neifer wrote:[color=blue]
> Hi, could somebody please explain why the following statement consumes
> six extents:
>
> CREATE TABLE T1 (C1 INT, C2 BLOB(1K)) IN TS1
>
> I see one extent for the extent map and one extend for data pages. How
> many extents does this BLOB thing need?
>
> Thanks in advance.
>
> Regards,
> Markus[/color]

--
Pierre Saint-Jacques - Reply to: sesconsjunk at attglobaljunk dot com
Reconstruct address: Remove the two junk and replace at and dot by
their symbols.
IBM DB2 Cerified Solutions Expert - Administration
SES Consultants Inc.

  #3  
Old November 12th, 2005, 09:00 AM
Markus Neifer
Guest
 
Posts: n/a
Default Re: How many extents does a BLOB need?

Hi Pierre, thank you for your reply. I know about the tablespace
overhead and was thinking about extents consumed by T1 only. Maybe
some more information will clarify this. I create TS1 with

CREATE TABLESPACE TS1
MANAGED BY DATABASE USING (FILE 'TS1_CONT' 120)
EXTENTSIZE 10

and LIST TABLESPACES SHOW DETAIL says total pages 120, usable pages
110 and used pages 30. So far, so good. Now i create a simple table

CREATE TABLE T2 (C1 INT, C2 CHAR(250)) IN TS1

and LIST TABLESPACES SHOW DETAIL says used pages 50. That's ok because
each object (table, index, LOB) needs 2 extents. However, after
creating the following table

CREATE TABLE T1 (C1 INT, C2 BLOB(1K)) IN TS1

LIST TABLESPACES SHOW DETAIL says used pages 110. I see one extent for
the extent map and one extend for data pages. I thought the BLOB would
need 2 extents, as any other object. But if i sum it up, i get only 4
extents, not 6.

What am i missing?

Markus

Pierre Saint-Jacques <sescons@attglobal.net> wrote in message news:<41000778.3020802@attglobal.net>...[color=blue]
> The other four extents are used by the tblspc itself.
> One for the con tainer tag, one for header data, one for space map, one
> for header object data. These four will always appear in each container.
> From then on, each object will be created with two extents; one for the
> extent map and one pre-allocated empty for the data to come in. As rows
> grow, more extents are allocated and identified in the extent map which
> will then grow new ones as needed.
>
> HTH, Pierre.[/color]
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 205,248 network members.