Split a string [message #396216] |
Sun, 05 April 2009 02:15  |
J1357
Messages: 33 Registered: November 2008
|
Member |
|
|
Gurus,
Sorry to missed on this info as parallely working on similar type of code.
I'm having one procedure where user inputs 2 values :
id which is 11111,22222,33333,etc
and string which is combination of parsed strings parsed with character '#'.
Now if user passes 1 and string which is
filename=oracle.exe&mdfid=123455&relmdfid=44545454#filename=java.exe&mdfid=4343434&relmdfid=656565, these would get inserted in a table.
Look of table would be :
id file_name
----------------------------------------------------------------------------------------------
11111 filename=oracle.exe&mdfid=123455&relmdfid=44545454
11111 filename=java.exe&mdfid=4343434&relmdfid=656565
Can you provide me with working code for the same?
Help appreciated ..Hope everything has been cleared from my side this time.
|
|
|
|
|
|
|
Re: Split a string [message #396427 is a reply to message #396216] |
Mon, 06 April 2009 10:54  |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
And that brings us straight back to the original thread:
http://www.orafaq.com/forum/m/394214/129190/#msg_394214
J1357:
We still don't know why you think you need to write any code to handle ampersands (&).
Although I'm beginning to think the problem is you don't really understand what define does.
PL/SQL does not treat amphersands any different to any other character.
SQLplus does treat them differently - it treats them as substitution variables and you need to use set define off to stop it doing that.
However - Vamsi's example above did not use set define off and it didn't need to. sqlplus does not check the value supplied for a substitution variable for more substitution variables.
|
|
|