johnnyk Posted June 22, 2006 Share Posted June 22, 2006 Does NOW() in MySQL change according to daylight savings?If it does, should I use ... INTERVAL + 5 + date(I)?Also, what's the correct way to add an interval in MySQL?Now() + INTERVAL 5orDATE_ADD(NOW(), INTERVAL 5 HOURS) Quote Link to comment https://forums.phpfreaks.com/topic/12602-mysql-now/ Share on other sites More sharing options...
akitchin Posted June 22, 2006 Share Posted June 22, 2006 not sure about DST, but the correct syntax is:DATE_ADD(NOW(), INTERVAL 5 HOUR)the interval type needs to be singular, which has always tripped me up. Quote Link to comment https://forums.phpfreaks.com/topic/12602-mysql-now/#findComment-48325 Share on other sites More sharing options...
trq Posted June 22, 2006 Share Posted June 22, 2006 This would depend upon the servers OS setting I would think. Quote Link to comment https://forums.phpfreaks.com/topic/12602-mysql-now/#findComment-48328 Share on other sites More sharing options...
johnnyk Posted June 22, 2006 Author Share Posted June 22, 2006 [!--quoteo(post=386692:date=Jun 21 2006, 09:51 PM:name=thorpe)--][div class=\'quotetop\']QUOTE(thorpe @ Jun 21 2006, 09:51 PM) [snapback]386692[/snapback][/div][div class=\'quotemain\'][!--quotec--]This would depend upon the servers OS setting I would think.[/quote]Is there a way to find out if my server uses DST on MySQL without waiting until the fall? My host outsources and asking them won't solve anything. Quote Link to comment https://forums.phpfreaks.com/topic/12602-mysql-now/#findComment-48516 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.