Hello,
I actuelly getting data from my getway to my remote server.As intergration, I use HTML.
I got a json filr format and I useing the time in metedata.
2018-05-22T16:36:31.959545235Z
I save all data into my gateway and I have a table names ‘collection’. A collection is a collection of measures sent at the same time through the gateway.
In order to make sure, I not have double same entry, I make a check comparing the data/time
In my table, the following
2018-05-22T16:36:31.959545235Z
is saved as
2018-05-22 16:36:31
the number after the dot is removed (is normal)
In any case, when I use a MySQL request in php, to see if the entry exist, it never work
$sql_selectc = ‘SELECT c.collection_date,c.ttn_m_time FROM collections AS c
WHERE c.ttn_m_time = "’.$m_time.‘“”
ORDER BY c.collection_created ASC’;
Then, I wunder, if there is way to remove
2018-05-22T16:36:31.959545235Z
to
2018-05-22 16:36:31
or
2018-05-22T16:36+0200
With PHP/MySQL
Or if there is another way to compare a entry with the date/time and the metada.time of the json file.
Or how would you do it?
Cheers
.