Board index   FAQ   Search  
Register  Login
Board index PHP PHP General

incrementing DATETIME

General discussions related to php

Moderators: macek, egami, gesf

Postby TheIceman5 » Tue Feb 11, 2003 5:40 am

why you using the dat type field format, just use a big int and store the time in the 10 figure number like 1045645444 and then modify it form there and convert it into ya date into any format you want, it seems much easier to me.
TheIceman5
New php-forum User
New php-forum User
 
Posts: 28
Joined: Tue Jan 21, 2003 9:31 pm

Postby *JaH* » Fri Feb 14, 2003 4:08 pm

make a timestamp-cell in mysql.....if you select the timestamp-field, read it like:

SELECT UNIX_TIMESTAMP(time) as epoch_time

then you can do anything you want with it :)

and that way you can do so much more nice and tricky mysql-features with that cell (like selecting a certain day range etc)
*JaH*
New php-forum User
New php-forum User
 
Posts: 80
Joined: Fri Jan 31, 2003 4:18 pm


Return to PHP General

Who is online

Users browsing this forum: Google [Bot] and 2 guests

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.

cron