Try the following statement:
SELECT b.segmentid, b.user_id, count(b.user_id) from segments b
WHERE b.typeid = 100
group by b.segmentid, b.user_id
having count(b.user_id) > 1
|
Results 1 to 4 of 4
Thread: group byThreaded View
|
Click Here to Expand Forum to Full Width |