I have this awful field that I managed to get what I want using Substring. However, I am unable to remove the leading space when there is one.
This is what I am using:
Case When Left(ah.TokenString,2)='21' AND ah.TransactionType='DPA' THEN LTRIM(SUBSTRING(ah.TokenString,27,40))
Thanks for your help