Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 4E5FE475B22 for ; Mon, 26 Aug 2002 15:26:52 -0400 (EDT) Received: from ias.digitro.com.br (unknown [200.247.100.134]) by postgresql.org (Postfix) with ESMTP id CA1D2475AEB for ; Mon, 26 Aug 2002 15:26:50 -0400 (EDT) Received: from serverdgt.daf.digitro.com.br (serverdgt.daf.digitro.com.br [192.2.2.10]) by ias.digitro.com.br (8.11.6/8.11.1) with ESMTP id g7QJMGb11304 for ; Mon, 26 Aug 2002 16:22:16 -0300 Received: from dgtac ([192.168.160.152]) by serverdgt.daf.digitro.com.br (8.11.1/8.8.7) with SMTP id g7QJQIt30344 for ; Mon, 26 Aug 2002 16:26:18 -0300 Message-ID: <00ee01c24d36$7246a3c0$98a0a8c0@dgtac> From: "Vilson farias" To: Subject: Deleting large amount of data. Date: Mon, 26 Aug 2002 16:26:14 -0300 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_00EB_01C24D1D.4C0806E0" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200208/307 X-Sequence-Number: 5421 This is a multi-part message in MIME format. ------=_NextPart_000_00EB_01C24D1D.4C0806E0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Greetings, I'm having some perfomance problems related with large amount of tuples= in a table, so I decided to start programming some shell scripts to be pla= ced in crontad to remove old data every night.=20 Now, my questions are :=20 If I just execute a DELETE * FROM WHERE call_start < '2002-08-21' and cal= l_start > '2002-08-20', and that interval has 100.000 tuples, does DELETE s= tart and commit a transaction for every single deletion? And If I put a BEGIN at the beginning and a COMMIT at the end, do deleted= tuples overload transaction logs?=20 Finally, what's the best thing to do? Best regards. ---------------------------------------------------------------------------= ----- Jos=E9 Vilson de Mello de Farias Software Engineer D=EDgitro Tecnologia Ltda - www.digitro.com.br - Brazil APC - Customer Oriented Applications E-mail: vilson.farias@digitro.com.br Tel.: +55 48 281 7158=20 ICQ 11866179 ---------------------------------------------------------------------------= ----- Jos=E9 Vilson de Mello de Farias Analista de Sistemas =20 D=EDgitro Tecnologia Ltda - www.digitro.com.br APC - Aplicativos Orientados ao Cliente E-mail: vilson.farias@digitro.com.br Tel.: +55 48 281 7158=20 ICQ 11866179 ------=_NextPart_000_00EB_01C24D1D.4C0806E0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Greetings,
 
    I'm having some perfo= mance=20 problems related with large amount of tuples in a table, so I decided to st= art=20 programming some shell scripts to be placed in crontad to remove old data e= very=20 night.
 
   Now, my questions are :=20
 
  If I just execute a DELETE * FROM= =20 WHERE call_start < '2002-08-21' and call_start >=20 '2002-08-20', and that interval has 100.000 tuples, does DELETE start and c= ommit=20 a transaction for every single deletion?
 
  And If I put a BEGIN at the begin= ning and=20 a COMMIT at the end, do deleted tuples overload transaction logs?
 
  Finally, what's the best thing to= =20 do?
 
Best regards.
 
------------------------------------------------------------------= --------------
Jos=E9=20 Vilson de Mello de Farias
Software Engineer
 
D=EDgitro Tecnologia Ltda - www.digitro.com.br - Brazil
= APC -=20 Customer Oriented Applications
E-mail: vilson.farias@digitro.com.br
Tel.:=20 +55 48 281 7158
ICQ 11866179
------------------------------------------------------------------= --------------
Jos=E9=20 Vilson de Mello de Farias
Analista de Sistemas
 
D=EDgitro&nb= sp;=20 Tecnologia  Ltda   -   www.digitro.com.br
APC - Aplicati= vos=20 Orientados ao Cliente
E-mail: vilson.farias@digitro.com.br
Tel.:=20 +55 48 281 7158
ICQ 11866179
------=_NextPart_000_00EB_01C24D1D.4C0806E0--