You are here: Re: FormatDateTime Revisited « PHP Programming Language « IT news, forums, messages
Re: FormatDateTime Revisited

Posted by Pedro Graca on 09/27/22 11:37

John K wrote:
> I need to format the date going "into" the database.

mysql> create table foo (id int primary key auto_increment, t1 datetime, t2 timestamp);
Query OK, 0 rows affected (0.03 sec)

mysql> insert foo (t1, t2) values (20060117201703, 20060117201703);
Query OK, 1 row affected (0.05 sec)

mysql> select * from foo;
+----+---------------------+---------------------+
| id | t1 | t2 |
+----+---------------------+---------------------+
| 1 | 2006-01-17 20:17:03 | 2006-01-17 20:17:03 |
+----+---------------------+---------------------+
1 row in set (0.00 sec)

--
If you're posting through Google read <http://cfaj.freeshell.org/google>

 

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

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