Jump to content

This topic is 7282 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I need to be able to create a filemaker calculation field that converts a given date into unix format. I have the formula for excel:

[(DATE(Year,Month,Day)+TIME(Hour,Minute,Second)-25569)*(86400)]

but converting the date to a numerical format in excel is not equaling the number that filemaker gives me. Help! confused.gif

Posted

I need to be able to create a filemaker calculation field that converts a given date into unix format. I have the formula for excel:

[(DATE(Year,Month,Day)+TIME(Hour,Minute,Second)-25569)*(86400)]

but converting the date to a numerical format in excel is not equaling the number that filemaker gives me. Help! confused.gif

Posted

I need to be able to create a filemaker calculation field that converts a given date into unix format. I have the formula for excel:

[(DATE(Year,Month,Day)+TIME(Hour,Minute,Second)-25569)*(86400)]

but converting the date to a numerical format in excel is not equaling the number that filemaker gives me. Help! confused.gif

Posted

Try for the date part:

((Date Entry - Date(1,1,1970)) * 86400)

I've never used this, I only collected it from some post.

HTH

Lee

Posted

Try for the date part:

((Date Entry - Date(1,1,1970)) * 86400)

I've never used this, I only collected it from some post.

HTH

Lee

Posted

Try for the date part:

((Date Entry - Date(1,1,1970)) * 86400)

I've never used this, I only collected it from some post.

HTH

Lee

Posted

Oh, you mean Unix time. Try this:

Let ( [

UnixEpoch = Timestamp ( Date ( 1 ; 1 ; 1970 ) ; Time (0 ; 0 ; 0 ) ) ;

Offset = Time ( GMT ; 0 ; 0 ) ;

Now = Timestamp ( theDate ; theTime - Offset )

] ;

GetAsNumber ( Now - UnixEpoch )

)

/*

GMT = the difference, in hours, between your local time and GMT

Example:

for EASTERN STANDARD TIME enter -5;

for EASTERN DAYLIGHT SAVING TIME enter -4.

*/

Posted

Oh, you mean Unix time. Try this:

Let ( [

UnixEpoch = Timestamp ( Date ( 1 ; 1 ; 1970 ) ; Time (0 ; 0 ; 0 ) ) ;

Offset = Time ( GMT ; 0 ; 0 ) ;

Now = Timestamp ( theDate ; theTime - Offset )

] ;

GetAsNumber ( Now - UnixEpoch )

)

/*

GMT = the difference, in hours, between your local time and GMT

Example:

for EASTERN STANDARD TIME enter -5;

for EASTERN DAYLIGHT SAVING TIME enter -4.

*/

Posted

Oh, you mean Unix time. Try this:

Let ( [

UnixEpoch = Timestamp ( Date ( 1 ; 1 ; 1970 ) ; Time (0 ; 0 ; 0 ) ) ;

Offset = Time ( GMT ; 0 ; 0 ) ;

Now = Timestamp ( theDate ; theTime - Offset )

] ;

GetAsNumber ( Now - UnixEpoch )

)

/*

GMT = the difference, in hours, between your local time and GMT

Example:

for EASTERN STANDARD TIME enter -5;

for EASTERN DAYLIGHT SAVING TIME enter -4.

*/

This topic is 7282 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.