You are viewing limited content. For full access, please sign in.

Question

Question

Fill Date of Birth field from a pattern match

asked on March 31, 2017 Show version history

I'm trying to fill the Date of Birth (DOB) field from a pattern match for large batches of scanned student files. The files have come to me with multiple naming conventions. The DOB/file name is formatted as

 

(\d{1,2}[-]\d{1,2}[-]\d{4})[_]\D+[_]\D+[_]\D+[_][J][R] in some documents and

 

it is formatted as (\d{1,2}[-]\d{1,2}[-]\d{2})[_]\D+[_]\D+[_]\D+[_][J][R] in others.

 

How can I get the birthdates in the file names to populate my DOB fields? I'm using pattern matching for Last, First, Middle, and Suffix.  The DOB field is formatted as   /  /    .

 

 

Thanks!

 

John

0 0

Replies

replied on March 31, 2017

This pattern should work   (\d\d-\d\d-\d\d+)

0 0
replied on April 2, 2017

Since your day and month fields can be 1 or 2 digits and the year can be 2 or 4 this regexp should work:  (\d+-\d+-\d+)
That should allow you to directly update a DOB field that is set to a Short Date format.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.