4WebHelp
 FAQ  •  Search  •  User Groups  •  Forum Admins  •  Smilies List  •  Statistics  •  Rules   •  Login   •  Register
Toggle Navigation Menu

 Unixtime Conversion
Post New TopicReply to Topic
View Previous Topic Print this topic View Next Topic
Author Message
johnc21
Junior WebHelper
Junior WebHelper


Joined: 25 Aug 2006
Posts: 1

PostPosted: Fri Aug 25, 2006 3:11 pm (11 years, 3 months ago) Reply with QuoteBack to Top

Hi,
I am not well versed in SQL or PHP but desperately need help. I have "inherited" a database that I just need to retrieve the data to save for future use if needed. However the dates are in Unixtime and I cannot read them. I saw the Unixtime converter but I have over 300 dates that I need to convert. Can anyone tell me if there is an SQL query that I can run to get the dates to convert? Or if there is a formula I can put in Excel to convert the dates? Any help would be greatly appreciated. Thank you.
John
OfflineView User's ProfileFind all posts by johnc21Send Personal Message
plusplus
Junior WebHelper
Junior WebHelper


Joined: 01 Dec 2010
Posts: 5

PostPosted: Mon Dec 06, 2010 7:36 pm (7 years ago) Reply with QuoteBack to Top

Hi John,

for Excel

=(CELL-"1/1/1970")*60*60*24

where CELL is the cell containing a regular date

good luck!
OfflineView User's ProfileFind all posts by plusplusSend Personal MessageVisit Poster's Website
dave476
Junior WebHelper
Junior WebHelper


Joined: 18 Aug 2012
Posts: 2
Location: UK

PostPosted: Sat Aug 18, 2012 1:47 pm (5 years, 4 months ago) Reply with QuoteBack to Top

Depends on which flavour of SQL you are talking about.

But in MySQL you can use:

FROM_UNIXTIME()

converts from an Unix timestamp stored in a DB to human-readable date format.

________________________________
Recipes for Restaurant-style Curries and Welsh Legends and Folk-tales
OfflineView User's ProfileFind all posts by dave476Send Personal MessageVisit Poster's Website
Display posts from previous:      
Post New TopicReply to Topic
View Previous Topic Print this topic View Next Topic


 Jump to:   




You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot edit your posts in this forum.
You cannot delete your posts in this forum.
You cannot vote in polls in this forum.


Page generation time: 0.0798 seconds :: 18 queries executed :: All Times are GMT
Powered by phpBB 2.0 © 2001, 2002 phpBB Group :: Based on an FI Theme