Neidio i'r brif gynnwys

Dates from Custom Fields

yn Date and Time Operations
Rhestr o awduron
Cyhoeddwyd: Mar 16, 2017|Diweddarwyd diwethaf: Nov 3, 2022

If you’re retrieving a date stored in a custom field, it is stored as an integer timestamp rather than real date types, so you need to pass it through the FROM_UNIXTIME function first, e.g.:

SELECT DATE_FORMAT(FROM_UNIXTIME(tickets.custom_data[1]), '%Y-%m-%d') AS 'Date
copy
DefnyddiolAnnefnyddiol
tudalen nesafFinding an Interval between Two Date/Times
tudalen flaenorolRelative Dates with Placeholders

Mewngofnodwch neu cofrestrwch i gyflwyno sylw.