Convert DDMMMYYYY to YYYYMMDD

A swapping-ground for Regular Expression syntax

Convert DDMMMYYYY to YYYYMMDD

Postby kiwidrader » Wed Sep 14, 2016 6:34 am

Hi,
I am trying to convert filenames that have a date in the format DDMMMYYYY (04MAY2011) to the format YYYYMMDD (20110504).
The name preceding the date is variable and may also contain numbers and letters.
I have seen some examples of DDMMYYYY with the date using all numbers, but not a combination of numbers and letters.
I have played around a bit with regEx, but just can't seem to get it right.

tx
Stuart
kiwidrader
 
Posts: 1
Joined: Wed Sep 14, 2016 6:27 am

Re: Convert DDMMMYYYY to YYYYMMDD

Postby therube » Sun Sep 18, 2016 3:16 pm

The name preceding the date is variable and may also contain numbers and letters.

Can you provide some more specific examples.

DD & YYYY should be straight forward, I would think.
MMM (as letters) to MM (as numbers) might need the help of 14:JavaScript renaming?
therube
 
Posts: 394
Joined: Mon Jan 18, 2016 6:23 pm


Return to Regular Expressions