-----Original Message-----
From: Stefick Ronald S Contr ESC/HRIDA [mailto:[EMAIL PROTECTED]
Sent: Monday, January 26, 2004 11:29 PM
To: Multiple recipients of list ORACLE-L
Subject: String manipulationI'm trying to separate a string into 3 values:
The string is:
mystr1~mystr2~mystr3Here is the code so far:
1 select substr(subject,1,instr(subject,'~')-1) first,
2 substr(subject,instr(subject,'~')+1, instr(subject,'~',1,2)-1) second,
3 substr(subject,instr(subject,'~',1,2)+1,length(subject))
4 from test_table
5 where test_column=1700455The result I get is:
mystr1
mystr2~mystr3
mystr3The result I want is:
mystr1
mystr2
Mystr3TIA,
Scott Stefick
MILPDS OCP Oracle DBA
[EMAIL PROTECTED]
210-565-2540
___________________________________________________________________________
This email and any attached to it are confidential and intended only for the individual or entity to which it is addressed. If you are not the intended recipient, please let us know by telephoning or emailing the sender. You should also delete the email and any attachment from your systems and should not copy the email or any attachment or disclose their content to any other person or entity. The views expressed here are not necessarily those of Churchill Insurance Group plc or its affiliates or subsidiaries. Thank you.
Churchill Insurance Group plc. Company Registration Number - 2280426. England.
Registered Office: Churchill Court, Westmoreland Road, Bromley, Kent BR1 1DP.