here is what i am trying to do.i have a PHP CLI script
> that will open a dbx file extract records from the dbf file > one by one check is the record is already on the linux server > (mysql database). if the record is already on the linux server > then it will update the mysql database on the linux server. but > if the record is not in the mysq database running on linux then > it will insert the record. the script is running on win2k server.
Is this a one time thing that you need to do or is it continuous? If it's a one time thing, why not just dump one database and import it into the other? If continuous, why not enable replication? You could also use the REPLACE() query, which will UPDATE if the row exists and INSERT if it doesn't. Also, if you remove your indexes while you INSERT a bunch of data and then rebuild them afterwards, it'll be faster.
-- ---John Holmes...
Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
php|architect: The Magazine for PHP Professionals – www.phparch.com
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php