Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SELECT COUNT(A.TypeID) AS TypeA, COUNT(B.TypeID) AS TypeB FROM InfoTable AS A
- JOIN InfoTable AS B ON A.AccountID = B.AccountID
- WHERE ((A.TypeID < 3) AND (B.TypeID > 3)) GROUP BY A.AccountID
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement