Oracle - Count distinct values of a column
Posted
by Luciana Borela
on Stack Overflow
See other posts from Stack Overflow
or by Luciana Borela
Published on 2010-06-09T13:02:29Z
Indexed on
2010/06/09
20:42 UTC
Read the original article
Hit count: 136
Hi
I have this table:
Reason|Area_Code|Id
x dig 1
x dig 2
y dig 3
h util 4
x dig 5
I'm trying for a SQL that returns:
Reason|Amount of distinct Reason|Area_code
x 3 dig
y 1 dig
h 1 util
I will use this result to plot a chart. I don´t have any idea on how this SQL can be done. Could you help me?
© Stack Overflow or respective owner