In that case, you will have "finer" (more smaller) groups.

We must first form groups of employee tuples based on:

Then:

Schematically:
DNO sex Avg ++++  4  M  45000  ++++  5  M  60000  ++++  5  F  50000  ++++ 
DNO sex Avg
++++
 4  M  45000 
++++
 4  F  0  < You may expect this result !!!
++++
 5  M  60000 
++++
 5  F  50000 
++++

The correct result set is (from above):
DNO sex Avg ++++  4  M  45000  ++++  5  M  60000  ++++  5  F  50000  ++++ Does not contain a row with 0 !!! 

