Hey folks, I am having some trouble backing up a database from a server in NY to a server in California.
When I do this: mysqldump myDatabase | mysql --host=otherTimeZone.com [etc] the data gets there but the timestamp columns (timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP) end up three hours later. I have learned about the --tz-utc option to mysqldump and that would be lovely, but it's only available in MySQL 5.1.2 and I would rather not get into upgrading (from 5.0.45-log). I thought it would be clever to write a shell script that says echo 'SET time_zone="US/Eastern";' > $DUMP; and then concatenates the rest of the dump to the file which is then fed into the mysql client -- but it doesn't work. Any ideas, o wise ones? Gratefully, -- David Mintz http://davidmintz.org/ The subtle source is clear and bright The tributary streams flow through the darkness
_______________________________________________ New York PHP Community MySQL SIG http://lists.nyphp.org/mailman/listinfo/mysql NYPHPCon 2006 Presentations Online http://www.nyphpcon.com Show Your Participation in New York PHP http://www.nyphp.org/show_participation.php
