Formula applying apostrophe + date to column

Excellica

New Member
Joined
Feb 19, 2020
Messages
6
Office Version
  1. 2016
Platform
  1. Windows
Hello!

I have a kolumn in my spreadsheet that contains dates in this format: YYYY-MM-DD. The column is auto-formatted as "Date". However, I need to import this column into a CRM system that happens to re-write the dates into an unwanted date format. After some trying back and forth I managed to get it imported correctly by adding an apostrophe " ' " before the date in the file (auto-formatting it to "General"). But, when I try to add this apostrophe to all rows through a formula e.g.: ="'"&A2, Excel rewrites the date to a 5-digit number (formatting auto changes to "General"). ¯\_(ツ)_/¯

So my date that should look like this 'YYYY-MM-DD, ends up like this '12345.

What to do...?
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
try
=TEXT(A2,"yyyy-mm-dd")
or
="'"&TEXT(A2,"yyyy-mm-dd")

but I think the first will be enough
 
Last edited:
Upvote 0
Date: 2020-02-12
My output when I try your suggestion: 'yyyy-00-12
So neither year nor month is correct :(
 
Upvote 0
textdate.png


what is you excel language?
maybe there should be :jjjj or rrrr
how is word "year" in your language?
month ?
day ?
 
Upvote 0
Oooh it worked! It's in Swedish so it's åååå-mm-dd :biggrin: THANK YOU!
 
Upvote 0
glad you are HAPPY :)
thanks for the feedback

btw. you can set Location in your Account details :Sverige or Sweden, less troubles in the future
 
Upvote 0

Forum statistics

Threads
1,215,734
Messages
6,126,543
Members
449,316
Latest member
sravya

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top