extracting substring from variable length string

Primary tabs


I am working in Ensemble (Health Connect) and doing an HL7 translation

I have what I hope is a simple coding question (but for the life of me, I am struggling).  I have a requirement where I need to extract the last 5 characters of a variable length string.  The return value should be those last 5 characters.  For example - String = CE325ACCT98765 where the return value of the function needs to be 98765.  I am just drawing a blank.

thank you,


  • 0
  • 0
  • 210
  • 0
  • 1


should do it .  * marks the last char in the string

*-4 ist he first of the last five chars