Looks like i found a solution.
my regex finds "12" and "12 43 999" in your target string
‘blah blah 12 dsa 12 43 999 etc.’ (should be in fixed size font)
^^ ^^^^^^^^^^
The regex below
\b\d(?(?=\x20*\d).)*\b
uses the power of if-then-else conditional construct. (Without "else"
branch here)
The regex acts as follows. Having found the first digit in a series of
digits (\b guarantees that it is the first) it checks what it has to
the right of the current position. If it is
1. a space or spaces or no spaces at all \x20*
followed by
2. a digit \d
then it includes the symbol to the right into the whole match.
The star ensures that this check&inclusion will be repeated cyclically
as many times as possible, but zero times is OK as well (it is a
nature of a star).
Note that the \d located before the first opening round bracket will
catch single digits, anyway.
Excerpt from PowerGREP regex tutorial:
=====================================
A special construct (?ifthen|else) allows you to create conditional
regular expressions. If the if part evaluates to true, then the regex
engine will attempt to match the then part. Otherwise, the else part
is attempted instead. The syntax consists of a pair of round brackets.
The opening bracket must be followed by a question mark, immediately
followed by the if part, immediately followed by the then part. This
part can be followed by a vertical bar and the else part. You may omit
the else part, and the vertical bar with it.
For the if part, you can use the lookahead and lookbehind constructs.
Using positive lookahead, the syntax becomes (?(?=regex)then|else).
Because the lookahead has its own parentheses, the if and then parts
are clearly separated.
--
Regards, Eugeny