Importing a CSV file containing dates. The relevant date element has settings as follows:
List format : d/m/Y
Form format: d/m/Y
CSV Import Format: normal
I've tried importing the CSV file with the dates formatted as:
15/01/2008 (d/m/Y)
15/01/08 (d/m/y)
01/15/2008 (m/d/Y)
and each permutation results in the error:
The error message displays the time string respectively as:
15/01/2008
15/01/08
15/01/2008 (doesn't swap month and day here ... is that a clue?)
As far as I understand the documentation, the import function is expecting the date to match the format set in "List format", ie d/m/Y, and therefore the first format I tried should have worked...
(Note, the CSV file has been prepared using openoffice and is UTF-8)
List format : d/m/Y
Form format: d/m/Y
CSV Import Format: normal
I've tried importing the CSV file with the dates formatted as:
15/01/2008 (d/m/Y)
15/01/08 (d/m/y)
01/15/2008 (m/d/Y)
and each permutation results in the error:
Code:
DateTime::__construct(): Failed to parse time string (15/01/2008) at position 0 (1): Unexpected character
The error message displays the time string respectively as:
15/01/2008
15/01/08
15/01/2008 (doesn't swap month and day here ... is that a clue?)
As far as I understand the documentation, the import function is expecting the date to match the format set in "List format", ie d/m/Y, and therefore the first format I tried should have worked...
(Note, the CSV file has been prepared using openoffice and is UTF-8)