-
help with using Group by clause
I am running the following query, and getting an error
select office_code, sum(exam1_cost) as RgnLabCost, avg(exam1_cost) as AvgRgnLabCost, sum(exam2_cost) as RgnPhysCost, avg(exam2_cost) as AvgRgnPhysCost
From MasterExam
Group by office_code
error message:
The system has attempted to use an undefined value, which usually indicates a programming error, either in your code or some system code.
Null Pointers are another name for undefined values.
this being run against oracle 10g db.
the order by field has no NULL values, of course some of the costs fields are null but that is it.
any ideas what is throwing the error?
-
Are you sure cost column is throwing the error, can you remove avg cost from the query and try it to see if error goes away
-
if I remove the office code and group by clause, then it runs fine.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|