Totara Learn Open Discussions

Importing entries into database activity - date format

 
Matthew Carson
Importing entries into database activity - date format
by Matthew Carson - Wednesday, 19 May 2021, 10:06 PM
 

Hi all

I'm trying to import entries into the database activity. Every field is working except for the date field. My csv file has the date field in dd/mm/yyyy format, however it will always import as Jan 1 1970.

Even if I put an entry in manually, export that entry out, and then reimport that entry, it will import as Jan 1 1970.

Is there any way to import the date field and have the value as it is in the csv file?

Thanks

- Matt

Craig Eves
Re: Importing entries into database activity - date format
by Craig Eves (Totara Support) - Thursday, 20 May 2021, 2:56 PM
Group Totara

Hi Matthew

Can you try using the Unix timestamp for the date you want and format this as a number in the csv file .

This is inconsistent with other areas but the database activity is not on the roadmap to improve in the near future.

Regards


Matthew Carson
Re: Importing entries into database activity - date format
by Matthew Carson - Thursday, 20 May 2021, 8:18 PM
 

Thanks Craig, that worked :)


All good that it's not in the roadmap, just needed a solution!

- Matt