Hi
I have an address that contains 3 parts seperated by commas.
Eg. A Big Company, 13 New Street, 12345 Glasgow
I need to split this into 3 variables
I can get the first and last parts using
select SUBSTR('A Big Company, 13 New Street, 12345 Glasgow', 0, INSTR('A Big Company, 13 New Street, 12345 Glasgow', ',')-1)
from dual
Returns A Big Company
select substr('A Big Company, 13 New Street, 12345 Glasgow', instr('A Big Company, 13 New Street, 12345 Glasgow', ',', 1, 2)+1)
from dual
Returns 12345 Glasgow
I just cannot figure out how to return the middle part
Help appreciated
Gus