Is it possible to use a regexp function to identify the numeric value after a certain string of text - within one field?
examples of my values within COL_A are TAX_NO 1234567890, - I would like to match on any values where TAX_NO is present, but I would also like to bring back the number that follows also - the result should be TAX_NO 1234567890.
Which is easy enough as a LIKE '%TAX_NO&', but the problem is that we could have other characters in this field that would read: TAX_NO 1234567890 2 apple street, also occasions where it could be TAX_NO1234567890 2 apple street -
how can I extract just that TAX_NO and the 10 digit number that follows?
Ideally this will be used to match on, using a reference file where TAX_NO 1234567890 is correct and will match against another dataset where this value could be in a number of fields as mentioned with additional text.
Data Sample:
COL_A - DESIRED RESULT
TAX_NO 1234567890 MR SMITH - TAX_NO 1234567890
1/ TAX_NO 1234567890 - TAX_NO 1234567890
TAX_NO1234567890 2 APPLE ST - TAX_NO 1234567890
MR SMITH TAX_NO 1234567890 - TAX_NO 1234567890
SMITH TAX_NO 1234567890 2 APPLE - TAX_NO 1234567890
tia
Dan