From dcutrone@afip.gov.ar Thu, 17 Jan 2002 11:08:50 -0800 From: "Diego Cutrone" Date: Thu, 17 Jan 2002 11:08:50 -0800 Subject: RE: used segment space in bytes Message-ID: MIME-Version: 1.0 Content-Type: text/plain Title: Dieter Oberkofler Stationery Hi Dieter:     As you've said, you can use dbms_space for this job. This package tells you how many blocks has the object and where's the HWM. And if you use the dbms_space.free_blocks() procedure, it will also report how many blocks below the HWM are in the freelists.     You can also use this query to know how many blocks hold at least one row:   (ORACLE 7) SELECT COUNT(DISTINCT SUBSTR(rowid,15,4)||SUBSTR(rowid,1,8)) FROM TABLE.       You can easily change it to work in Oracle 8 too by using the dbms_rowid package.   HTH Greetings Diego Cutrone  
----- Original Message -----
From: Oberkofler, Dieter To: Multiple recipients of list ORACLE-L Sent: Thursday, January 17, 2002 2:11 PM Subject: used segment space in bytes hi guys!   what would be the easiest way to compute the space in bytes used by a segment? it is rather easy to determine the # of used blocks by a specific segment by looking at the dba_extents for example. but how many blocks have been really used in one of those extents. i guess i would be able to compute the free blocks by using the dbms_space package but it just seems to complicated. any hints ... ?   thank you   -do