Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

  • Newbies
Posted

Hi there,

My problem is I have an office booking system that is built with PHP and uses MySQL as the database.

I am trying to use the data stored in the MySQL database with Filemaker, however, the date and time in the MySQL database is stored in the following format: "1247700600" (An integer)

I had a bit of a look around in the PHP files and seems to have found something that I think codes that date and time into something called strftime.

Does anyone know a custom function in Filemaker or any other way that would decode this back into a readable format for use in Filemaker.

Any help would be much appreciated.

Posted

That integer is most likely a unix timestamp (i.e. the number of seconds since midnight Jan 1st 1970). Use the following in your Select statement for import, or create a view with the following field added to the table to add to your relationship graph.


mysql>

 select FROM_UNIXTIME(1247700600) as myDate;

+---------------------+

| myDate              |

+---------------------+

| 2009-07-15 16:30:00 | 

+---------------------+

1 row in set (0.00 sec)





Filemaker will interpret the MySQL date as a FM Date type.

This topic is 5603 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.