Hello everyone,
I know there is already a lot on Regular Expressions to find on the forum, but could you please help me with the following:
(We don't have the scripting module to use.)
This is my string:
2016-03-08
year-month-day
It is the string value from a selectable date value from a metadatafield in a checkpoint.
I'd like to switch it to:
day-month-year
or select the values from year, month and day separately to save them in their own new variable in the following checkpoint.
Does anybody have a suggestion?
Year is no problem, \d{4}
But I can't get month and day in the right way.
Thanks in advance for the assistance!!
RexEx without the Scripting Module
Re: RexEx without the Scripting Module
So, not exactly sure how to do this without private data since I don't really do inserts into metadata. You should be able to use "define text with variables" > Metadata > Date to do this. I haven't used it at all, but I'm guessing that the "Format" property either takes the format of the existing date or the format of the date you want it in. Hopefully, it's the former, and you can specify yyyy-mm-dd there. Maybe something else more experienced with this can chime in, or you could provide an example flow to play around with.
Chat: open-automation @ gitter
Code: open-automation & dominickp @ GitHub
Tools: Switch, Pitstop, EPMS, Veracore, PageDNA, SmartStream, Metrix
Code: open-automation & dominickp @ GitHub
Tools: Switch, Pitstop, EPMS, Veracore, PageDNA, SmartStream, Metrix
Re: RexEx without the Scripting Module
Hi,
I second Gabriel. In the metadata dialog, just set metadata type to date. Set the date value to the xpath and use modifiers to rearrange the date.

Hope that helps,
Loic
http://www.ozalto.com
I second Gabriel. In the metadata dialog, just set metadata type to date. Set the date value to the xpath and use modifiers to rearrange the date.

Hope that helps,
Loic
http://www.ozalto.com
Re: RexEx without the Scripting Module
Hi,
Your hint for the metadata-date setting works fine!
In the beginning I was looking for a regular expression to solve the problem, but this different property works even better.
Thank you for the assistance.
Greetings from Holland
Mireille
Your hint for the metadata-date setting works fine!
In the beginning I was looking for a regular expression to solve the problem, but this different property works even better.
Thank you for the assistance.
Greetings from Holland

Mireille
Re: RexEx without the Scripting Module
Hi Mireille,
Glad I could help !
Loic
Glad I could help !
Loic