Skip to content
Advertisement

Substring to Get value only after first occurrence of : in Oracle SQL

I have data in below format in an Oracle table column:

I want to have data in below format i.e to have distinct first string after first occurrence of ::

I can get the value for first record using below query

But I am unable to get it for others if there are more than one : in a column value.

Any guidance would be great.

Advertisement

Answer

You can use two more arguments:

Here is a db<>fiddle.

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement