You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

How to convert text to date in Numbers

I have a csv file with data I want to load into Numbers. The csv file contains a column with dates (no time). The dates are formatted as "DD.MM.YYYY", e.g. "16.12.2019" for 12. dec 2019.


How do I load this into Numbers and have the column properly recognized as dates?


Please do not include any answers that requires me to change the date format in macOS.

Posted on Jun 29, 2020 6:01 AM

Reply
Question marked as Top-ranking reply

Posted on Jun 29, 2020 11:27 AM

You could use the function SUBSTITUTE for changing the " . " to " / ", like this:

Substitute modifies 16.12.2019 to 16/12/2019. The format is Automatic, hence still "TEXT", but Numbers will recognise the content as a date as shown in the next cell D2.

Formula in D2: C2 – 0, to keep the same date, then formatted as shown.


Paul.


3 replies
Question marked as Top-ranking reply

Jun 29, 2020 11:27 AM in response to Nicolai Henriksen

You could use the function SUBSTITUTE for changing the " . " to " / ", like this:

Substitute modifies 16.12.2019 to 16/12/2019. The format is Automatic, hence still "TEXT", but Numbers will recognise the content as a date as shown in the next cell D2.

Formula in D2: C2 – 0, to keep the same date, then formatted as shown.


Paul.


Jun 29, 2020 7:38 AM in response to Nicolai Henriksen

Hi Nicolai,


No need to change the date format in macOS.

Try this. It involves some work, but you can hide the intermediate columns and Save as Template for future use.



Fill these formulas down.

Formula in B2 =LEN(A2)

Formula in C2 =FIND(".",A2,1)

Formula in D2 =FIND(".",A2,C2+1)

Formula in E2 =RIGHT(A2,B2−D2)

Formula in F2 =MID(A2,C2+1,D2−C2−1)

Formula in G2 =LEFT(A2,C2−1)

Formula in H2 =DATE(E2,F2,G2)


Column I shows how you can format the date to your preferred display.


Yes, some work, but when you hide the "work" columns and Save as Template:



Regards,

Ian.




How to convert text to date in Numbers

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.