General information
Category:
Coding, syntax & commands
Hello alls.
I have a field called (phone) this has the format [(#####)-########], for sample (03564)-462193, where the firts numbers are the prefix and the others are the phone number. I need divide the field in two variables, just one before the (-) and before the (-). The problem is that not always the prefix has the same lengt. In consequence I dont know how many places count to divide the field.
I did a matrix with 16 row y 1 colum where each subindex save each one the phone fiel charters to then search the symbol. I did this:
DIMENSION TTEL[16]
I=1
DO WHILE I <= 16
STORE SUBSTR(TELEFONO,I,1) TO TTEL[I]
I = I + 1
LOOP
ENDDO
Is this Ok,or Is there any one that know How did it better...?
Because then I get the posicion I have to get each charter and put in the variables.
TIA.
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only