![]() |
Why is user.joindate an 'int' field?
I am trying to format the sql but I can't because joindate, is a 'int' field
mysql> select DATE_FORMAT(joindate, '%m.%d.%Y') AS joindate from user limit 0,1; +----------+ | joindate | +----------+ | NULL | Why would the unix timestamp be stored in a 'int' field? |
the unix timestamp is the ammount of seconds that have been since 1.1.1970, thats why it's saved as an int-val.
|
because its too long to be a smallint field and a timestamp is always an integer since its seconds since the epoch.
|
Why not store it in a 'TIMESTAMP' field? Do you know any way I can use date_format on it, since its not in a 'TIMESTAMP' field.
|
Use the vbdate function:
PHP Code:
|
All times are GMT. The time now is 07:18 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|