with compiere database i am trying ro show
between two dates.
column:
designation
qty sale (depot) client sales
qty-sale
The problem is (at least) in the group by clause. Oracle does not allow column aliases in group by. You can readily fix this with a subquery:
select t.*
from (select . . .
from . . .
where . . .
) t
group by . . .
order by . . . ;
In other words, put everything but the group by and order by in a subquery. Then put those clauses in the outer query.