Archives of the TeradataForum
Message Posted: Fri, 08 Apr 2005 @ 20:32:55 GMT
Subj: | | Re: Extracting piece of data from a string of text |
|
From: | | ulrich arndt |
Julie,
substring(test from position('ac-' in test)+3)
give you everything after the first occurance of ac-
position(',' in substring(test from position('ac-' in test)+3))
give you the position of the first ',' after ac-
-1 will be the length of the string you are looking for
substring(substring(test from position('ac-' in test)+3)
from 1 for position(',' in substring(test
from position('ac-' in test)+3))-1)
should than be the code which give you what you are looking for, as long as you only search the first occurance in a string. In case of
recursive searches check the ETL process if possible.
Ulrich
|