plsql cursors group by for loop exclude NULLS

example input :
col1 col2 col3 col4 etc..
A        null    3   null
A         5        null  4
A        6          3      2
B         2         4     1

I should expect output just with record "B". group by  A should be there only if col3 has no NULLS
Rajavel67Asked:
Who is Participating?
 
slightwv (䄆 Netminder) Commented:
If you need anything else just ask.

If not, don't forget to close the question.

If you need help with that please look here:  How do I close my question?
http://support.experts-exchange.com/customer/portal/articles/2527982
0
 
slightwv (䄆 Netminder) Commented:
Assuming you want ALL rows/columns give this a try:
select col1, col2, col3, col4 from (
	select col1, col2, col3, col4,
		count(*) over(partition by col1) total_count,
		count(col3) over(partition by col1) col3_count
	from tab1
)
where total_count=col3_count
/

Open in new window


If you want something different, please provide expected results with your sample data.
0
 
Rajavel67Author Commented:
Thank you This helps !!
0
 
Rajavel67Author Commented:
much pleased !!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.