<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">The change is different for each record. No, the changes can’t be formulated in SQL.<div><br></div><div>The test database is 350 MB. Cleaning took about 2 minutes. There are a couple of things done here like removing white spaces etc. Literally over 80% of all calculations were spent in UpdateRecord according to Instruments.</div><div><br></div><div>I don’t see any speed loss in getting the data via SetString. Possible gains with accessing via index can only be very small. <br><div><br><div>Begin forwarded message:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><span style="font-family:'Helvetica'; color:rgba(0, 0, 0, 1.0);"><b>From: </b></span><span style="font-family:'Helvetica';">Jay Madren <<a href="mailto:jay@jaymadren.com">jay@jaymadren.com</a>><br></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><br></div><div><div dir="ltr"><div class="gmail_extra"><div class="gmail_default" style="font-family:tahoma,sans-serif;font-size:small">Well, updating a large text field across thousands of records is never going to be instantaneous. How slow is too slow? (how long is it taking per 100 or per 1000 records?)</div>
<div class="gmail_default" style="font-family:tahoma,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif;font-size:small">What are you updating the message text with? Is it constant, or variable depending on the message itself? If the changes can be formulated in SQL only, then it could be faster. But I assume you're not using a vserver, so the speed increase may be marginal.</div>
<div class="gmail_default" style="font-family:tahoma,sans-serif;font-size:small"><br></div></div></div></div></blockquote><div>Begin forwarded message:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><span style="font-family:'Helvetica'; color:rgba(0, 0, 0, 1.0);"><b>From: </b></span><span style="font-family:'Helvetica';">Steve Albin <<a href="mailto:steve@steve-albin.com">steve@steve-albin.com</a>><br></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><br></div><div><meta http-equiv="Content-Type" content="text/html charset=windows-1252"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Isn't it faster to use a numeric index of the field rather than the name of the field as well as avoiding the casting of the field type?<div><br></div><div><div>Instead of:</div><div>theCursor.Field("MessageBody").SetString theCleaner.execute</div><div><br></div><div>shouldn't it be </div><div>theCursor.varcharfield(1).value theCleaner.execute</div><div><br></div><div>Assuming the field is VarChar and in the first position of the cursor. Not sure this would make a significant difference, but I think it is faster, no?</div><div><br></div></div></div></div></blockquote></div><br><div apple-content-edited="true">
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Mit freundlichen Grüßen/Regards<br><br>Trixi Willius<br><br><a href="http://www.mothsoftware.com">http://www.mothsoftware.com</a><br>Mail Archiver X: The email archiving solution for professionals</div></span></span>
</div>
<br></div></body></html>