Query:

SELECT salesman_no, COUNT(order_no) as MAX_Sale, MAX(order_no)
as MAX_O_No FROM order_t5  GROUP BY salesman_no;

Output:


SALESM   MAX_SALE   MAX_O_
------ ----------   ------
s00001          1   o00001
s00002          1   o00002
s00003          1   o00003
s00004          1   o00004

Leave a Reply

Subscribe to Posts | Subscribe to Comments

All Notes on BCA

All Notes  on BCA
BCA all subjects notes

Total Pageviews

Translate

Powered by Blogger.

Copyright © All Notes on BCA