Regular expressions – Kofax Getting Started with Ascent Xtrata Pro User Manual
Page 180

Extraction
Ascent Xtrata Pro User's Guide
161
For a detailed description of the locator’s properties, see Project Builder User Interface
– Format Locator Properties Dialog Box.
Regular Expressions
Regular expressions are used to recognize patterns within textual data. They evaluate
text data and match an expression with the text in the document. In Ascent Xtrata
Pro, regular expressions are used in the Format Locator to identify items in a
document and return the value of a matching item.
Regular expressions are formats used to describe data in an abstract way. The most
important examples are listed the following table:
Format
Description
Example
Matches
Does Not Match
C
one character
a
a
b, A
. (dot)
Any character
b.g
big, bag, b1g, bbg
bg, baag
\d
Any single digit
a\d
a5, a8, a0
aA, ab, ?
[c
1
c
2
c
3
]
One character
out of a set
[abc]
a, b, c
1, 2, d, D, A
[c
1
-c
n
]
One character
out of a range
[a-z]
b, g,
1, 2, D, A
? (question
mark)
Optional part
x\d?
x, x7, x1
xx, xq
+ (plus)
One or more
\d+
4, 2323, 100
A112, 2b, X
* (times)
Zero or more
x\d*
x6, x, x100
100x, xx
{n}
Exactly n times
y{3}
yyy
yy, yyyy
{m,n}
Between m and n
times
\d{5,9}
12345, 999999999
1234, 999999999999
\
Escape special
characters
\$ \\ \- \? \.
$ \ - ? .
()
Group characters a(\$\$)?b
a$$b, ab
a$b, a$$