Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

date format conversions

Hi All,

I am trying to convert the following format:

Date :  Sep 2017 to 08-2017 

Any suggestions please?

Regards

15 Replies
maxgro
MVP
MVP

maybe you have to ltrim some spaces

1.png

Anonymous
Not applicable
Author

Excellent Bhargav, your left trim with Youssef's Code worked.

Thanks so much.

bhargav_bhat
Creator II
Creator II

Hi Rudra,

Can you please mark it as helpful if it answered your question

Regards,

Bhargav

pradosh_thakur
Master II
Master II

Hi Rudra

its great that you got the answer but you can try this in the future if you are not really sure about the space in dates.

for example

'  SEP 2017'  :- It has some leading space as well as one space between sep and 2017

'SEP    2017  '  :- It has some trailing  space as well as two  spaces between sep and 2017


what i generally do is


date#(purgechar(date_field,' '),date format withoutspace)


for example

DATE(date#(purgechar(date_field,' '),'MMMYYYY'))


Hope you will find this helpful .


regards

Pradosh

Learning never stops.
Anonymous
Not applicable
Author

Nice one Pradosh, appreciate your suggestion.

Regards

Anonymous
Not applicable
Author

Thank you very much Massimo

Regards