🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #586

Re: Slow updatebatch (insert)

#586
From: Mark Guerrieri
Date: Thu, 15 Sep 2005 17:13
26 lines
1943 bytes
You could send the server (via the TADOConnection->Execute method) specific
ALTER TABLE commands before/after applying you batch updates do
disable/enable the updating of indexes while inserting.  I don't remeber the
specific commands, but you can look them at mysql.com under the INSERT speed
optimization section.

Also, you could write your data to a text file and send the server a LOAD
DATA INFILE command which is about as fast as using the MySQL command line.

Mark

"Curt" <noemailaddress> wrote in message
news:4328495a$3@newsgroups.borland.com...
> I'm attempting to insert 10,000 records to a very simple MySQL table.  I
use
> a TADOConnection with a TADODataSet and cached updates.  The problem is
that
> the updatebatch process takes several minutes to complete.  Is there a
> faster way to pump this many records into a table ?  From the MySQL
command
> line I can insert over 3000 records in less than a second.
>
> Thanks,
> Curt
>
>
Technical Details
Message-ID: <4329ab7e$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!news.moat.net!news-out.newsfeeds.com!propagator3-LAX.newsfeeds.com!news-in.newsfeeds.com!news-in.superfeed.net!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <4328495a$3@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10698b,a6fd54a27b79a630
X-Google-Attributes: gid10698b,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Mark Guerrieri" <mguerrieri@nospam_cmsgrp.com>
Newsgroups: borland.public.cppbuilder.database.ado
References: <4328495a$3@newsgroups.borland.com>
Subject: Re: Slow updatebatch (insert)
Date: Thu, 15 Sep 2005 13:13:51 -0400
Lines: 28
Organization: Creative Marketing Strategies
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 209.50.174.82
Message-ID: <4329ab7e$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1126804350 209.50.174.82 (15 Sep 2005 10:12:30 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!news.moat.net!news-out.newsfeeds.com!propagator3-LAX.newsfeeds.com!news-in.newsfeeds.com!news-in.superfeed.net!caladan.landsraad.net!newsgroups.borland.com!not-for-mail