RE: How to break up a big transaction?
Posted in 2000
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_001_01BF5962.38A49340
Content-Type: text/plain;
charset="iso-8859-1"
Or check out Art Kagel's dbdelete program on
www.iiug.org -> Software -> utils2_ak
-----Original Message-----
From: ackerbau@us.ibm.com [mailto:ackerbau@us.ibm.com]
Sent: Friday, January 07, 2000 2:50 PM
To: informix-list@iiug.org
Subject: Re: How to break up a big transaction?
Lena --
If you code the delete as a cursor that implicitly deletes one record at a
time, it should not adversely affect logging. The only way you'd fill up
your logs is if you issued a "delete from table where . . ." in dbaccess.
A foreach cursor in SPL should do the trick very nicely for you -- no
explicit commit statements required if you delete a record at a time in the
cursor.
-mka
Michael Ackerbauer
SP Platform Evaluation Test
Systems Verification/Integration Webmaster
Please respond to lena_peltonen@my-deja.com
Sent by: owner-informix-list@iiug.org
To: informix-list@iiug.org
cc:
Subject: How to break up a big transaction?
Hi all,
I'd need perform a huge delete operation
(about million rows). I wouldn't like to add several logs
for this single transaction that will be run very rarely.
So how can I break up a delete operation so that it would do
commit e.g. after every 5000 rows?
I was told that I could use dbloader but is there any way to do it
from SPL or C/ESQL script?
Any help would make me most grateful.
Best Regards
Lena
Sent via Deja.com http://www.deja.com/
Before you buy.
------_=_NextPart_001_01BF5962.38A49340
Content-Type: text/html;
charset="iso-8859-1"
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2448.0">
<TITLE>RE: How to break up a big transaction?</TITLE>
</HEAD>
<BODY>
<P><FONT SIZE=2>Or check out Art Kagel's dbdelete program on</FONT>
</P>
<P><FONT SIZE=2>www.iiug.org -> Software -> utils2_ak</FONT>
</P>
<P><FONT SIZE=2>-----Original Message-----</FONT>
<BR><FONT SIZE=2>From: ackerbau@us.ibm.com [<A HREF="mailto:ackerbau@us.ibm.com">mailto:ackerbau@us.ibm.com</A>]</FONT>
<BR><FONT SIZE=2>Sent: Friday, January 07, 2000 2:50 PM</FONT>
<BR><FONT SIZE=2>To: informix-list@iiug.org</FONT>
<BR><FONT SIZE=2>Subject: Re: How to break up a big transaction?</FONT>
</P>
<BR>
<P><FONT SIZE=2>Lena --</FONT>
</P>
<P><FONT SIZE=2>If you code the delete as a cursor that implicitly deletes one record at a</FONT>
<BR><FONT SIZE=2>time, it should not adversely affect logging. The only way you'd fill up</FONT>
<BR><FONT SIZE=2>your logs is if you issued a "delete from table where . . ." in dbaccess.</FONT>
</P>
<P><FONT SIZE=2>A foreach cursor in SPL should do the trick very nicely for you -- no</FONT>
<BR><FONT SIZE=2>explicit commit statements required if you delete a record at a time in the</FONT>
<BR><FONT SIZE=2>cursor.</FONT>
</P>
<P><FONT SIZE=2>-mka</FONT>
</P>
<P><FONT SIZE=2>Michael Ackerbauer</FONT>
<BR><FONT SIZE=2>SP Platform Evaluation Test</FONT>
<BR><FONT SIZE=2>Systems Verification/Integration Webmaster</FONT>
</P>
<BR>
<BR>
<BR>
<BR>
<BR>
<P><FONT SIZE=2>Please respond to lena_peltonen@my-deja.com</FONT>
</P>
<P><FONT SIZE=2>Sent by: owner-informix-list@iiug.org</FONT>
</P>
<BR>
<P><FONT SIZE=2>To: informix-list@iiug.org</FONT>
<BR><FONT SIZE=2>cc:</FONT>
<BR><FONT SIZE=2>Subject: How to break up a big transaction?</FONT>
</P>
<BR>
<BR>
<P><FONT SIZE=2>Hi all,</FONT>
</P>
<P><FONT SIZE=2>I'd need perform a huge delete operation</FONT>
<BR><FONT SIZE=2>(about million rows). I wouldn't like to add several logs</FONT>
<BR><FONT SIZE=2>for this single transaction that will be run very rarely.</FONT>
</P>
<P><FONT SIZE=2>So how can I break up a delete operation so that it would do</FONT>
<BR><FONT SIZE=2>commit e.g. after every 5000 rows?</FONT>
</P>
<P><FONT SIZE=2>I was told that I could use dbloader but is there any way to do it</FONT>
<BR><FONT SIZE=2>from SPL or C/ESQL script?</FONT>
</P>
<P><FONT SIZE=2>Any help would make me most grateful.</FONT>
</P>
<P><FONT SIZE=2>Best Regards</FONT>
</P>
<P><FONT SIZE=2>Lena</FONT>
</P>
<BR>
<P><FONT SIZE=2>Sent via Deja.com <A HREF="http://www.deja.com/" TARGET="_blank">http://www.deja.com/</A></FONT>
<BR><FONT SIZE=2>Before you buy.</FONT>
</P>
<BR>
</BODY>
</HTML>
------_=_NextPart_001_01BF5962.38A49340--