If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > index size calc

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-23-11, 11:09
Mathew_paul Mathew_paul is offline
Registered User
 
Join Date: Oct 2007
Posts: 200
index size calc

hi

Want to calc the size of index ,i found lots of queries but not able to get the prefect one even REORG_IX_STATE procedure has ISIZE but not sure its in bytes or MB etc.

nleaf * pagesize , Please provide a query for the same if you have.

regds
Paul
Reply With Quote
  #2 (permalink)  
Old 05-23-11, 14:57
schintala schintala is offline
Registered User
 
Join Date: Apr 2005
Location: USA
Posts: 119
I used to execute this SQL to get size of Index in z/OS. Take a look and see it it helps you.

SELECT CREATOR,NAME,
DEC(SPACEF,11,2) AS "SPACEF IN KB",
DEC(SPACEF,11,2)/2097152 AS "SPACEF IN GB"
FROM SYSIBM.SYSINDEXES
WHERE (CREATOR IN ('XXXXXXX','XXXXXXX') OR TBCREATOR LIKE 'ABC%')
AND DEC(SPACEF,11,2) / 2097152 > 0.1
ORDER BY SPACEF DESC
WITH UR
;
Reply With Quote
  #3 (permalink)  
Old 05-25-11, 05:02
Mathew_paul Mathew_paul is offline
Registered User
 
Join Date: Oct 2007
Posts: 200
pls suggest

select (sum(cast(i****eaf as bigint) * ts.pagesize/1024)/1024) as indexsiz
eMB from syscat.indexes i , syscat.tablespaces ts where i.tbspaceid = ts.tbspace
id and i.tabname = 'tabname' group by ts.pagesize.

regds
Paul
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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