Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Open Source > Linux
|
Linux General discussion of programming the various flavors of Linux operating systems.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Linux section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 22nd, 2006, 02:59 PM
Friend of Wrox
 
Join Date: Sep 2005
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Corey
Default Convert UNIX Time to MS Access

Hello everyone

I’m trying to find a way to convert a UNIX timestamp to the standers universal timestamp. At this point I can’t even make sense of the UNIX time stamping system.

I would like to be able to use Microsoft access to do the conversion.

Does anyone one a why to convert the UNIX timestamp into a MMDDYY formatted time. Any help would be greatly appreciated


Thanks

Corey


 
Old January 23rd, 2006, 12:25 PM
Friend of Wrox
 
Join Date: Dec 2003
Posts: 488
Thanks: 0
Thanked 3 Times in 3 Posts
Default

> standers universal timestamp
You're thinking of the US localized 'middle endian' fomat, I imagine:
MM/DD/YYYY or something?

The only universal standards are the RFC2822 timestamp you get on emails, and the ISO8601 (YYYY-MM-DD) ones.

When you're talking about the unix timestamp, I'm guessing you have a single, rather large number like this:
1138032417

This is the number of seconds since Midnight UTC on Jan 1st 1970 (which is when Unix time began). You should be able to do this with perl if you have it (or use the strftime call from c/c++ on unix).

Here's an example in perl:
#!/usr/bin/perl -w
use strict;
use POSIX qw(strftime);

print strftime("%d/%m/%Y\n", localtime('1138032417'));
# EOF

HTH
Charlie

--
Don't Stand on your head - you'll get footprints in your hair
                                           http://charlieharvey.org.uk
                                              http://charlieharvey.com
 
Old April 26th, 2006, 03:27 PM
Registered User
 
Join Date: Sep 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Can i know what these open source is all about?i have a already running software commercially but since my professor gave me the assignment to find a way of modifying the software for a similar but different purpose,example is the e-mail extractor lite 1.4,He wants me to find the source code and see what i can do with it to develop a mobile or fax phone number extractor.
 Another problem i have now is that i don't not how to retrieve my hacked email address I.D, i discovered something like a yahoofreaker was used, and right i am confused.


 
Old May 1st, 2007, 11:25 AM
Registered User
 
Join Date: May 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Juhsepi
Default

I think that I'm in the same boat as Corey.

My coworkers and I have linked a DNS table into Access 2002 and the Date Stamped is in Unix format.

I need to now convert the Unix table to Something that MS Access can read. Unfortunately, I have reached the limits of my Access knowledge and can't seem to understand why Access doesn't like the Expression that I create to convert this.

The table that contains the date stamp, has the data stored in a General Number, Long Integer format. I cannot change just change the format because the results are pre 1900.

Don't know what other information is needed. HELP!
 
Old April 7th, 2009, 11:52 AM
Registered User
 
Join Date: Apr 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Use DateAdd

In T-SQL use the DateAdd function to add seconds to Jan 1, 1970.

DATEADD(second, [fieldname], '1970-01-01')





Similar Threads
Thread Thread Starter Forum Replies Last Post
Convert Ms Access report to MS Word doc kite Access 1 October 22nd, 2007 01:45 AM
I am trying to convert a MS Access Query to a SQL? WebLadyBug SQL Server ASP 3 March 9th, 2007 12:39 PM
Convert SQL to MS Access Corey Access 1 February 2nd, 2007 11:46 AM
Convert UNIX Time to MS Access Corey Access 1 January 23rd, 2006 12:32 AM
JRUN4 Unix with MS Access 2003 zaman1111 JSP Basics 0 February 10th, 2005 05:09 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.