Grooper 21.00.0082 is available as of 12-12-2023! Check the Downloads Discussion for the release notes and to get the latest version.
Grooper 23.00.0044 is available as of 06-20-2024! Check the Downloads Discussion for the release notes and to get the latest version.
Grooper 23.1.0026 is available as of 09-16-2024! Check the Downloads Discussion for the release notes and to get the latest version.
Grooper 24.0.0012 is available as of 10-10-2024! Check the Downloads Discussion for the release notes and to get the latest version.
Dealing with whitespace in data types
tgarnett
Posts: 76 ✭✭✭
How would you approach creating your Data Types when you are running into situation where you
are getting extra white space?
For instance I am creating my address Data type and I am getting a lot of
P. O. Box 4 35
where there is a space in between the 4 and the 3.
are getting extra white space?
For instance I am creating my address Data type and I am getting a lot of
P. O. Box 4 35
where there is a space in between the 4 and the 3.
0
Best Answer
-
RandoCalrisian Posts: 195 adminI actually made some Grooper objects to help illustrate this problem and solution. These are Grooper 2.6 objects.
This first file (RegEx Currency with possible space or Period - Batch.zip) is a Batch Object containing a sample Page Object I created to illustrate the problem (forcing a period, a space, and a non-space.) It has been OCRed.
The second file (RegEx Currency with Possible Space or Period - DT) is a Folder Object with a Data Type containing Data Formats Illustrating both solutions.Randall Kinard
rkinard@bisok.com6
Answers
The "better" approach (starting in 2.6) would be to leverage Fuzzy RegEx mode on the format/pattern. The pattern would end up being something like:
P[.] O[.] Box \d{1,4}
As long as the Fuzzy Match percentage is reasonable, this technique should work well and will remove the additional space in the output.
Product Manager
mharrison@bisok.com
rkinard@bisok.com
Product Manager
mharrison@bisok.com