Regex with dates
Thread poster: Reed James

Reed James
Chile
Local time: 11:02
Member (2005)
Spanish to English
Apr 13, 2019

I would like to know the best way to check date formats. Sometimes I have to convert US date format to UK date format. Can this be done with a regular expression in the search and replace dialogue?

 

Dan Lucas  Identity Verified
United Kingdom
Local time: 14:02
Member (2014)
Japanese to English
If even humans struggle... Apr 13, 2019

Reed James wrote:
Sometimes I have to convert US date format to UK date format.

I think the issue is that a date like "02/02/02" is ambiguous, but valid under either UK dd/mm/yy and US mm/dd/yy conventions. If even you can't tell which is which by looking at it, how can the regex? You might say "Well, that's unlikely to happen very often", but it's those edge cases that will get ya if you do a bulk find and replace.

Problems like this explain why the ISO 8601 format (yyyy-mm-dd) exists.

Regards,
Dan


 

Jean Lachaud  Identity Verified
United States
Local time: 09:02
English to French
+ ...
Wordfast 5.8 Online Help says: Apr 13, 2019

"Note: Select Use Regex to search on regular expressions or wild card characters.", which should answer your question.

 

Reed James
Chile
Local time: 11:02
Member (2005)
Spanish to English
TOPIC STARTER
How about the months written out? Apr 13, 2019

Usually what happens is that I will see 8 US date such as January 2, 1955 and I want to change into 22 January 1955. I don't necessarily need to in the find and replace dialog placed out. All I need to do is to find all of the months written out instead of doing an individual search for each month (January, February, March…) which is tedious and unnecessary.

 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

Regex with dates

Advanced search


Translation news related to Wordfast





SDL MultiTerm 2019
Guarantee a unified, consistent and high-quality translation with terminology software by the industry leaders.

SDL MultiTerm 2019 allows translators to create one central location to store and manage multilingual terminology, and with SDL MultiTerm Extract 2019 you can automatically create term lists from your existing documentation to save time.

More info »
WordFinder Unlimited
For clarity and excellence

WordFinder is the leading dictionary service that gives you the words you want anywhere, anytime. Access 260+ dictionaries from the world's leading dictionary publishers in virtually any device. Find the right word anywhere, anytime - online or offline.

More info »



Forums
  • All of ProZ.com
  • Term search
  • Jobs
  • Forums
  • Multiple search