Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Retrieving distinct count from a comma separated values from a column?

Learning_BeeApr 20 2016 — edited Apr 20 2016

I have a column containing values like below, from which i need to comma separate the values and take the distinct count

Note: If there is any null or empty string that should not be considered for count

col1

===

ab,bc,cd,cd,cd

ab,ab

ab,' ',bc,bc,' '

output:

=========

col1

====

3

2

2

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 18 2016
Added on Apr 20 2016
12 comments
2,584 views