You are here: Re: date mystery « PHP Programming Language « IT news, forums, messages
Re: date mystery

Posted by Gordon Burditt on 11/24/94 11:28

>> Why doesn't this return anything ?
>>
>> SELECT DATE_SUB('FROM_DAYS(TO_DAYS(2005-09-28 18:04:19))', INTERVAL 6 DAY)

'FROM_DAYS(TO_DAYS(2005-09-28 18:04:19))' is not a valid date.
Valid dates don't have a bunch of underscores, parentheses, and alphabetic
junk in them.

You might want:

SELECT DATE_SUB(FROM_DAYS(TO_DAYS('2005-09-28 18:04:19')), INTERVAL 6 DAY)

but I'm not sure I understand what the point of the FROM_DAYS and TO_DAYS
calls is.

Gordon L. Burditt

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация