Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Gett and tokens
#1
i need to have a token delimiter to be "," but gett doesnt seem to see that.
how can i do this?

here is a sample of my data.

"9/29/06","Xxxxx, YYY","9:30 AM","111-555-5555","(F)","12","-","-","-"


thanks.
A new blog on QM coding and automation.

The Macro Hook
#2
Code:
Copy      Help
str s=
;"9/29/06","Xxxxx, YYY","9:30 AM","111-555-5555","(F)","12","-","-","-"
ARRAY(str) a
tok s a -1 ",''" 4
int i
for i 0 a.len
,out a[i]
,
#3
rats...i found some data this is a little different in it. there is no comma in the second token so it's throwing off the token count. is there a way to use the "," ?



"9/29/06","Xxxxxxxxxx yyy","9:30 AM","111-222-3333","(F)","12","-","-","-"


thanks
A new blog on QM coding and automation.

The Macro Hook
#4
s.findreplace("'',''" "[1]")

Then tok or gett using delim "[1]".

(not tested)
#5
yeah, i was just thinking about that findreplace thing...did that with a | and then just used that as my delimiter...works great btw Big Grin


thanks for help.
A new blog on QM coding and automation.

The Macro Hook


Forum Jump:


Users browsing this thread: 1 Guest(s)