30,997
edits
Tag: 2017 source edit |
Tag: 2017 source edit |
||
| Line 501: | Line 501: | ||
And all select methods should translate date fields, coming from the database as a string in TZ of server (here '19700101030000'), into a timestamp field (integer) by calling the method db->jdate(). So this stores the date into memory as a GTM Timestamp integer. | And all select methods should translate date fields, coming from the database as a string in TZ of server (here '19700101030000'), into a timestamp field (integer) by calling the method db->jdate(). So this stores the date into memory as a GTM Timestamp integer. | ||
'''How to manage | '''How to manage dates with no hours (just day):''' | ||
For insert/update, you must convert it with db->idate(value, 'gmt') so for 0, you will get '19700101000000'. | For insert/update, you must convert it with db->idate(value, 'gmt') so for 0, you will get '19700101000000'. | ||