« How to Lose Customers by saving a little money - Lenovo X300 | Main | Weird Calendar page for September 1752 (the month they dropped 10 days from) »

May 06, 2008

Comments

Stephen

And this fails to do what you want, though it seems fine with the syntax. It rounds to the next day.

UPDATE log_table SET end_time = DATE_ADD(start_time, INTERVAL 0.506851 DAY);

But this works:

UPDATE log_table SET end_time = DATE_ADD(start_time, INTERVAL 0.506851 * 3600 * 24 SECOND);

The comments to this entry are closed.