jitendra gupta

jitendra gupta

  • NA
  • 7
  • 4.2k

sql query

Sep 16 2014 3:42 AM

Dear sir

I have two sql table Table1 and Table2 which have the following data

Table1

ID

ItemName

Quantity

1

Collar

100

2

freeze

200

3

collar

400

4

freeze

200

5

tv

200

6

tv

500

Table2

ID

ItemName

Quantity

1

Collar

70

2

collar

60

3

tv

200

4

freeze

50

5

tv

90

6

freeze

300

I want to find the difference of Sum of Quantity of both tables. And want to calculate like

Result

ItemName

Quantity

Collar

370

freeze

50

tv

410

Please help to execute sql query for solving this problem

Thanks advance


Answers (1)