From oracle-l-bounce@freelists.org  Thu Oct 27 08:17:58 2005
Return-Path: <oracle-l-bounce@freelists.org>
Received: from air891.startdedicated.com (root@localhost)
 by orafaq.com (8.12.10/8.12.10) with ESMTP id j9RDHhTk016785
 for <oracle-l@orafaq.com>; Thu, 27 Oct 2005 08:17:48 -0500
X-ClientAddr: 206.53.239.180
Received: from turing.freelists.org (freelists-180.iquest.net [206.53.239.180])
 by air891.startdedicated.com (8.12.10/8.12.10) with ESMTP id j9RDHTvX016712
 for <oracle-l@orafaq.com>; Thu, 27 Oct 2005 08:17:35 -0500
Received: from localhost (localhost [127.0.0.1])
 by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id B6FA12112A7;
 Thu, 27 Oct 2005 08:17:06 -0500 (EST)
Received: from turing.freelists.org ([127.0.0.1])
 by localhost (turing [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id 10681-10; Thu, 27 Oct 2005 08:17:06 -0500 (EST)
Received: from turing (localhost [127.0.0.1])
 by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 278002112A2;
 Thu, 27 Oct 2005 08:17:06 -0500 (EST)
Received: with ECARTIS (v1.0.0; list oracle-l); Thu, 27 Oct 2005 08:15:11 -0500 (EST)
Received: from localhost (localhost [127.0.0.1])
 by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id BD07C2110D3
 for <oracle-l@freelists.org>; Thu, 27 Oct 2005 08:15:11 -0500 (EST)
Received: from turing.freelists.org ([127.0.0.1])
 by localhost (turing [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id 10336-02 for <oracle-l@freelists.org>;
 Thu, 27 Oct 2005 08:15:11 -0500 (EST)
Received: from ga016a0c2.suntrust.com (mx5.suntrust.com [167.181.33.37])
 by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 653B921127B
 for <oracle-l@freelists.org>; Thu, 27 Oct 2005 08:15:11 -0500 (EST)
Received: from unknown (HELO GA016A0E10.corp.suntrust.com) (10.49.90.110)
  by ga016a0c2.suntrust.com with ESMTP; 27 Oct 2005 09:57:44 -0400
X-IronPort-AV: i="3.97,258,1125892800"; 
   d="scan'208,217"; a="231292691:sNHT28445724"
Received: from VA016A0E0.corp.suntrust.com ([10.15.164.100]) by GA016A0E10.corp.suntrust.com with Microsoft SMTPSVC(5.0.2195.6713); Thu, 27 Oct 2005 09:15:07 -0400
Received: from VA016A0E2.corp.suntrust.com ([10.15.164.102]) by VA016A0E0.corp.suntrust.com with Microsoft SMTPSVC(5.0.2195.6713); Thu, 27 Oct 2005 09:15:01 -0400
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
content-class: urn:content-classes:message
MIME-Version: 1.0
Priority: normal
Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C5DAF8.6ABF22E4"
Subject: RE: Strange Truncate Table Behaviour
Date: Thu, 27 Oct 2005 09:14:52 -0400
Message-ID: <52C70FF150F49E479DAF59C68A27149D01F0E1AC@va016a0e2.corp.suntrust.com>
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
Thread-Topic: Strange Truncate Table Behaviour
Thread-Index: AcXa9zSxwA8j6wkzRB2WQAuKGCt49gAAIq2Q
From: "Kline.Michael" <Michael.Kline@SunTrust.com>
To: <sbootsma@gbrownc.on.ca>, <oracle-l@freelists.org>
X-OriginalArrivalTime: 27 Oct 2005 13:15:01.0333 (UTC) FILETIME=[6FDB8850:01C5DAF8]
X-archive-position: 27675
X-ecartis-version: Ecartis v1.0.0
Sender: oracle-l-bounce@freelists.org
Errors-To: oracle-l-bounce@freelists.org
X-original-sender: Michael.Kline@SunTrust.com
Precedence: normal
Reply-To: Michael.Kline@SunTrust.com
X-list: oracle-l
X-Virus-Scanned: by amavisd-new-20030616-p9 (Debian) at avenirtech.net
X-mailscan-MailScanner-Information: Please contact the ISP for more information
X-mailscan-MailScanner: Found to be clean
X-MailScanner-From: oracle-l-bounce@freelists.org
X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on 
 air891.startdedicated.com
X-Spam-Level: 
X-Spam-Status: No, hits=-4.6 required=5.0 tests=AWL,BAYES_00,HTML_50_60,
 HTML_FONTCOLOR_UNKNOWN,HTML_MESSAGE autolearn=no version=2.63
------_=_NextPart_001_01C5DAF8.6ABF22E4
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Compare the results of dba_segments to dba_extents. I know with
partitions on 9.2.0.6 on HP, I had to change my query to use dba_extents
as dba_segments may show 2-5GB, but dba_extents showed 1 extent.

=20

Michael Kline

Database Administration

Outside 804.261.9446

Cell 804.744.1545

3-9446

=20

-----Original Message-----
From: oracle-l-bounce@freelists.org
[mailto:oracle-l-bounce@freelists.org] On Behalf Of Sam Bootsma
Sent: Thursday, October 27, 2005 9:06 AM
To: oracle-l@freelists.org
Subject: Strange Truncate Table Behaviour

=20

Yesterday I used the Oracle supplied script sptrunc.sql to truncate
StatsPack tables.  The truncate was not instantaneous (it takes a couple
of minutes) and when it is finished, select count(*) from a couple of
tables shows there are no rows in the table.

=20

However, the segments still take as much space as they did before the
truncate.  I tried truncating a table using the clause drop storage.  It
finished, and I queried dba_segments again to discover it was still
taking the same amount of space.  I come in to work this morning and
queried dba_segments again.  A lot of the space had been released (but
not all).  So it seems Oracle took its time freeing up extents. =20

=20

We are running Oracle 9.2.0.6 on AIX 5.  We are using LMT, min extents
is 1, initial extent and min_extlen for the tablespace is 64K (assuming
the value in dba_tablespaces is in bytes) and segment space management
is auto.  On the table where I did a manual truncate with the drop
storage clause (STATS$SQL_SUMMARY) the min_extents value is 1, and
initial extent is 1M.  I had tried this very same procedure six months
ago, and it worked fine - just as I had expected it to; six months ago
we were using Oracle 9.2.0.4. =20

=20

Has anybody experienced this type of behavior before with truncate?  Any
possible explanations?

=20

Thanks,

=20

=20

Sam Bootsma

George Brown College

 <mailto:sbootsma@gbrownc.on.ca> sbootsma@gbrownc.on.ca

416-415-5000 x4933=20
 =20
 =20
 =20
LEGAL DISCLAIMER=20
The information transmitted is intended solely for the individual or =
entity to which it is addressed and may contain confidential and/or =
privileged material. Any review, retransmission, dissemination or other =
use of or taking action in reliance upon this information by persons or =
entities other than the intended recipient is prohibited. If you have =
received this email in error please contact the sender and delete the =
material from any computer.=20
 =20
Seeing Beyond Money is a service mark of SunTrust Banks, Inc.=20
[ST:XCL]=20
=20
=20
=20
=20

------_=_NextPart_001_01C5DAF8.6ABF22E4
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<HTML xmlns:eXclaimer=3D"http://www.exclaimer.co.uk">
<HEAD>
<META http-equiv=3D"Content-Type" content=3D"text/html; =
charset=3DUTF-16">
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3DUTF-16">
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Dus-ascii">




<meta name=3DGenerator content=3D"Microsoft Word 10 (filtered)">

<style>
<!--
 /* Font Definitions */
 @font-face
	{font-family:Tahoma;
	panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman";}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline;}
span.emailstyle17
	{font-family:Arial;
	color:windowtext;}
span.EmailStyle18
	{font-family:"Courier New";
	color:blue;
	font-weight:normal;
	font-style:normal;
	text-decoration:none none;}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
	{page:Section1;}
-->
</style>

</HEAD><BODY lang=3DEN-US link=3Dblue vlink=3Dpurple><DIV>
<FONT SIZE=3D"+0">
<DIV>
<FONT FACE=3D"Courier">
<DIV>
<FONT FACE=3D"Courier">
<DIV>
<FONT FACE=3D"Courier">
<DIV>
<FONT FACE=3D"Times New Roman">

<div class=3DSection1>

<p class=3DMsoNormal><font size=3D3 color=3Dblue face=3D"Courier =
New"><span
style=3D'font-size:12.0pt;font-family:"Courier New";color:blue'>Compare =
the
results of dba_segments to dba_extents. I know with partitions on =
9.2.0.6 on
HP, I had to change my query to use dba_extents as dba_segments may show =
2-5GB,
but dba_extents showed 1 extent.</span></font></p>

<p class=3DMsoNormal><font size=3D3 color=3Dblue face=3D"Courier =
New"><span
style=3D'font-size:12.0pt;font-family:"Courier =
New";color:blue'>&nbsp;</span></font></p>

<div>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3D"Courier =
New"><span
 style=3D'font-size:10.0pt;font-family:"Courier New";color:blue'>Michael =
Kline</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3D"Courier =
New"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:blue'>Database
Administration</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3D"Courier =
New"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:blue'>Outside
804.261.9446</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3D"Courier =
New"><span
style=3D'font-size:10.0pt;font-family:"Courier New";color:blue'>Cell =
804.744.1545</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3D"Courier =
New"><span
style=3D'font-size:10.0pt;font-family:"Courier =
New";color:blue'>3-9446</span></font></p>

<p class=3DMsoNormal><font size=3D3 color=3Dblue face=3D"Times New =
Roman"><span
style=3D'font-size:12.0pt;color:blue'>&nbsp;</span></font></p>

</div>

<div style=3D'border:none;border-left:solid blue 1.5pt;padding:0in 0in =
0in 4.0pt'>

<p class=3DMsoNormal><font size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;
font-family:Tahoma'>-----Original Message-----<br>
<b><span style=3D'font-weight:bold'>From:</span></b>
oracle-l-bounce@freelists.org [mailto:oracle-l-bounce@freelists.org] =
<b><span
style=3D'font-weight:bold'>On Behalf Of </span></b>Sam Bootsma<br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Thursday, October =
27, 2005
9:06 AM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> </span></font><font =
size=3D2
 face=3DTahoma><span =
style=3D'font-size:10.0pt;font-family:Tahoma'>oracle-l@freelists.org</spa=
n></font><font
size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;font-family:Tahoma'><br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> Strange Truncate =
Table
Behaviour</span></font></p>

<p class=3DMsoNormal><font size=3D3 face=3D"Times New Roman"><span =
style=3D'font-size:
12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Yesterday I used the Oracle supplied script =
sptrunc.sql to
truncate StatsPack tables.&nbsp; The truncate was not instantaneous (it =
takes a
couple of minutes) and when it is finished, select count(*) from a =
couple of
tables shows there are no rows in the table.</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>However, the segments still take as much space as =
they did
before the truncate.&nbsp; I tried truncating a table using the clause =
drop
storage.&nbsp; It finished, and I queried dba_segments again to discover =
it was
still taking the same amount of space. &nbsp;I come in to work this =
morning and
queried dba_segments again. &nbsp;A lot of the space had been released =
(but not
all).&nbsp; So it seems Oracle took its time freeing up extents.&nbsp; =
</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>We are running Oracle 9.2.0.6 on AIX 5.&nbsp; We are =
using
LMT, min extents is 1, initial extent and min_extlen for the tablespace =
is 64K
(assuming the value in dba_tablespaces is in bytes) and segment space
management is auto.&nbsp; On the table where I did a manual truncate =
with the
drop storage clause (STATS$SQL_SUMMARY) the min_extents value is 1, and =
initial
extent is 1M.&nbsp; I had tried this very same procedure six months ago, =
and it
worked fine &#8211; just as I had expected it to; six months ago we were =
using
Oracle 9.2.0.4.&nbsp; </span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Has anybody experienced this type of behavior before =
with
truncate?&nbsp; Any possible explanations?</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Thanks,</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;</span></font></p>

<div>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Sam Bootsma</span></font></p>

<p class=3DMsoNormal><st1:place><st1:PlaceName><font size=3D2 =
color=3Dnavy
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial;color:navy'>George</st1:Place=
Name>
<st1:PlaceName>Brown</st1:PlaceName> =
<st1:PlaceType>College</span></font></st1:PlaceType></st1:place></p>

<p class=3DMsoNormal><font size=3D3 face=3D"Times New Roman"><span =
style=3D'font-size:
12.0pt'><a href=3D"mailto:sbootsma@gbrownc.on.ca"><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>sbootsma@gbrownc.on.ca</span=
></font></a></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>416-415-5000 =
x4933</span></font></p>

</div>

<p class=3DMsoNormal><font size=3D3 face=3D"Times New Roman"><span =
style=3D'font-size:
12.0pt'>&nbsp;</span></font></p>

</div>

</div>

</FONT>
</DIV>
<DIV>
<FONT FACE=3D"Times New Roman">&nbsp;</FONT>
</DIV>
<DIV>
<FONT FACE=3D"Times New Roman">
</FONT>&nbsp;</DIV>
<DIV>
<FONT FACE=3D"Times New Roman">
</FONT>&nbsp;</DIV>
<DIV>
<FONT FACE=3D"Times New Roman">LEGAL DISCLAIMER<BR>The information =
transmitted is intended solely for the individual or entity to which it =
is addressed and may contain confidential and/or privileged material. =
Any review, retransmission, dissemination or other use of or taking =
action in reliance upon this information by persons or entities other =
than the intended recipient is prohibited. If you have received this =
email in error please contact the sender and delete the material from =
any computer.<BR>&nbsp;<BR>Seeing Beyond Money is a service mark of =
SunTrust Banks, Inc.<BR>[ST:XCL]</FONT>
</DIV>
</FONT>
</DIV>
</FONT>
</DIV>
</FONT>
</DIV>
</FONT>
</DIV></BODY></HTML>

------_=_NextPart_001_01C5DAF8.6ABF22E4--
--
http://www.freelists.org/webpage/oracle-l


