Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

double byte delimeter

Status
Not open for further replies.

BJZeak

Programmer
May 3, 2008
230
0
16
CA
Has anyone used this delimiter option with the ENTRY and NUM-ENTRIES commands?

I thought I had tested this feature using a double byte delimeter at some point but when I tried to use it in this fashion today it is not working the way I recollect.

chDelim = ":;".
chReadStr = "abc:;123:;;x;:y:z::;a1b"

DO inI = 1 TO Num-Entries(chReadStr, chDelim):
DISPLAY inI Entry(inI, chReadStr, chDelim).

For this to work properly it should return:
1 abc
2 123
3 ;x;:y:z:
4 a1b

Rereading the manual it leads me to believe Progress is talking about UNICODE vs ASCII delimiters where UNICODE is actually one character which is 2 bytes long ... so as I am working with an ASCII string I am guessing Progress probably is not going to allow using a UNICODE delimiter?
 
That's pretty much correct. The DELIMITER argument only takes a single character, regardless of byte length. Check out SESSION:CPINTERNAL to see what codepage you're using. If it's not UTF8, you're probably working with single byte characters.

Cheers, Mike.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top