Groups
Groups
Sign in
Groups
Groups
Oracle PL/SQL
Conversations
About
Send feedback
Help
Replace Nth occurence of a string
386 views
Skip to first unread message
Vlad
unread,
Oct 14, 2008, 10:40:52 AM
10/14/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Oracle PL/SQL
I need to replace the second occurrence of one string within another:-
E.g.
'Shoppingtrolley,Shoppingbasket'
needs to be come
'Shoppingtrolley,Emptybasket'
Any ideas?
TIA
Michael Moore
unread,
Oct 14, 2008, 1:39:45 PM
10/14/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Oracle...@googlegroups.com
SELECT SUBSTR (mystr, 1, INSTR (mystr, ',')) || 'Emptybasket'
FROM (SELECT 'Shoppingtrolley,Shoppingbasket' mystr
FROM DUAL);
Vlad
unread,
Oct 16, 2008, 11:36:58 AM
10/16/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Oracle PL/SQL
Cheers Michael ;-)
Reply all
Reply to author
Forward
0 new messages