Re: how to make multiple sql run faster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Usually a single transaction is faster than an insert a time (with or without union)
>
>> Hi all,
>>
>> I am inserting more than 5000 rows into sql database but its taking more
>> than 30 mins  to get it all the data inserted. I use union to insert
>> multiple rows of 20 at a time.
>>
>> What is the best way to make insert sql statement run faster

hi,

inserting 5000 rows should only take seconds.
if you are looping, optimize the code inside the loop.
or before entering the loop, get a connection first and the use the
connection inside the loop.
or maybe you could post snippets, that would surely be helpful.

cheers,
Virgil
http://www.jampmark.com
Free tips, tutorials, innovative tools and techniques useful for
building and improving web sites.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux