Highlander,
Cheers for the steer but no joy i'm afraid. ORA-00937: not a single-group group function.
Your idea sent me on convuloted round trip that eneded up with the following solution though.
ThanksCode:select mysite.region, count(decode(mysite.phase, 'Ph1', mytask.completed)) "Ph1", count(decode(mysite.phase, 'Ph2', mytask.completed)) "Ph2" from mysite, mytask where mytask.site = mysite.site group by mysite.region;
Ben




Reply With Quote