I need a query to get the following details :
For example, there are few rows with name 'DB2DB2' as
1 DB2DB2 X 10.00
2 DB2DB2 X 19.00
3 DB2DB2 X 27.00
4 DB2DB2 X 42.00
5 DB2DB2 Y 15.00
6 DB2DB2 M 10.00
7 DB2DB2 N 40.00
and a few other rows in the table like DB2DB2 so What I need is
The output should contains Sum of all X+Y MINUS Sum of all M+N = ?
Thanks in advance