Educational Materials like Computer, engineering, software and Property , Entertainment: How to Use a correlated subquery to get sum of colums for particular items
Custom Search

Subscribe Now: Feed Icon

February 7, 2012

How to Use a correlated subquery to get sum of colums for particular items

How to Use a correlated subquery to get sum of colums for particular items

select itemid from table1 A
where col1 = 'sp'
and amt <>
  (select sum(amt) from table1 B
   where B.itemid = A.itemid
   and col1 in ('a','b')
  )
;

0 comments:

Post a Comment

Follow by Email

Video Bar

Loading...

Followers

Educational Materials like Computer, engineering, software and Property , Entertainment

Recent Visitors

Active Search Results
Wink Bingo | Slots Tips | Football manager 2010 | blackjack free | Poker Stars
Submitdomainname.com