Forum Discussion
melwayconsultancy
Apr 14, 2023Copper Contributor
DATE to MONTH problem (TEXT function)
Hello everyone, I want to convert dates to months in the MONTH column. I tried the TEXT function, it worked for some dates but the other dates were unable to be converted. Some dates, such ...
HansVogelaar
Apr 14, 2023MVP
melwayconsultancy
Apr 14, 2023Copper Contributor
DATE: 4.1.2019 -> MONTH: =TEXT(B2;"mmmm") -> RESULT: November - This is ok
DATE: 6/25/19 -> MONTH: =TEXT(B3;"mmmm") -> RESULT: 6/25/19 - Not June.
Why is that?
The formula you sent did not work.
DATE: 6/25/19 -> MONTH: =TEXT(B3;"mmmm") -> RESULT: 6/25/19 - Not June.
Why is that?
The formula you sent did not work.
- HansVogelaarApr 14, 2023MVP
See if this formula works for you:
=TEXT(IF(ISTEXT(B2),DATE(2000,LEFT(B2,FIND("/",B2)-1),1),B2),"mmmm")
- Carola1225May 10, 2024Copper Contributorgreat help!!!!! thanks a lot!
- gabbyruiza2123Mar 11, 2024Copper Contributor
Thanks it does work.
- HansVogelaarApr 14, 2023MVP
Apparently your system does not recognize 6/25/19 as a valid date. Instead, it treats it as text, so the date format is ignored.
What happens if you do the following:
- Select the column with the date/time values.
- Press Ctrl+H to activate the Replace dialog.
- Enter / in the 'Find what' box and . in the 'Replace with' box.
- Click 'Replace All'.