Subject Re: [ib-support] insert optimization (long)
Author Erik S. LaBianca
Edwin,

Thanks for the suggestion. I installed MySQL 4.0.13, and changed my
script to create an InnoDB table. I was able to achieve 657534 records
inserted in 164 seconds (4009 records / sec).

Any other ideas?

Thanks

--erik


Edwin Pratomo wrote:
> On Wednesday 28 May 2003 02:11, Erik S. LaBianca wrote:
>
>>Daniel, Svein
>>
>>Thanks for the replies. I'll try to be more clear.
>>
>>Since the delphi+ibx situation has a bunch of other contributing
>>factors, i'll stick to the perl script i'm using for now. It DOES use
>>prepared inserts. I'll include the bulk of it below.
>>
>>The reason i feel it is slow, is that I converted it directly from using
>>MySQL. I ran the exact code below today, on the same machine, with both
>>MySQL 3.23.56 and FireBird 1.5RC2 using local connections to files on
>>the local filesystem. MySQL inserted 657534 records in 161 seconds (4084
>>records / sec). InterBase inserted 657534 records in 294 seconds (2236
>>records / sec).
>
>
> Using InnoDB as the MySQL's table handler should be slower than using the
> default MyISAM. When comparing to Firebird, using InnoDB seems to be more
> fair due to its multi versioning concurrency control.
> MyISAM is the speed demon when running in single user test environment, but I
> don't think it would scale well in multi user env, yes because it uses
> explicit table locking.
>
> rgds,
> Edwin.
>
>
>>I'd like to bring these numbers closer to each other, if possible.
>>
>>--begin perl code
>>#!/usr/bin/perl
>>my $dbh;
>>if ( 0 ) {
>> $dbh = DBI->connect("DBI:mysql:postal_db", "root", "")
>> or die "Couldn't connect to postal database: $DBI::errstr\n";
>>}
>>if ( 1 ) {
>> $dbh = DBI->connect(
>> "DBI:InterBase:/opt/postal.gdb",
>> "SYSDBA",
>> "masterkey"
>> );
>>}
>>$dbh->{AutoCommit} = 0;
>
>
>
>
> To unsubscribe from this group, send an email to:
> ib-support-unsubscribe@egroups.com
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>

--
Erik S. LaBianca <erik@...>
Developer / System Administrator, Interlink, Inc.
Voice: (269) 473-3103 Fax: (269) 473-1190
http://www.totalcirculation.com