At 12:24 -0700 4/20/04, Matthias Eireiner wrote:
Hi there,

I'm currently writing a Data Mining program in Perl, my problem is that the
writing to the database takes awful long.
Are there any ideas how to speed up the inserting and the updating, besides
using the bind operator?!

the SQLstatement looks like

"INSERT INTO `Counts` (`id`, `date`, `count`, `avg)VALUES ('', CURDATE(),
'$count', '$avg')"

or

"UPDATE `Counts` SET `count` = '$count', `avg` = '$avg' WHERE `id` = '$id'"

so if anybody has an idea how to get this done faster (dumping the data to a
csv file first and updating all at once, or something like this) I would
love to hear it.
thanks a lot in advance.


You might find some useful ideas here:

http://dev.mysql.com/doc/mysql/en/Insert_speed.html

--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to