Hi Patrick.
OK, then, if it is possible to have more than a underscore, then switch the scan function to a combination of the substr/indexc functions, like this:
[pre]
reverse(substr(reverse(TESTSTRING),indexc(reverse(TESTSTRING),'_')+1))
[/pre]
Same logic, which is reverse the string to find the first underscore, trim, then reverse the result again.
Both FIND, INDEXC or even INDEX will work.
FIND/INDEX searchs a substring in a string, while INDEXC searchs a character (or list of) in a string.
Cheers from Portugal.
Daniel Santos @
www.cgd.pt