I am using BASIC programming language for work. I have an example string here:
Eric*01*73839
By using the field function, I can grab either Eric or 01 like so:
ERIC = FIELD(STRING,"*",1)
01 = FIELD(STRING,"*",2)
However, if I wanted to grab the '73839' portion, how would this be done? I found it hard to find resources on google since it is so OLD.
**No,
FIELD(STRING,"*",3)
doesn't work.
You could always do some variation of converting the plain string to a dynamic string and extracting the third field. For example:
The specifics will depend on which flavor of multi-value BASIC you're using. It might have to be more like:
If it needs to be more dynamic (there may be more than three fields and you always need the last one), you'll need to use DCOUNT (or COUNT+1) to find the last field.