خرید بک لینک

Vote count: 0

I have this hypothetical table

transac_id     user_id        product
----------     -------        -------
  2051613       189546      monthly plan
  8746169       189546      commission fee
  7845946       998741      commission fee
  8897155       166235      sms
  6325477       166235      newsletter
  8897452       166235      commission fee
  4328941       302604      monthly plan
  8897415       309888      sms
  2564718       960007      commission fee
  7451352       960007      yearly plan

What I need to extract is the user_id that have bought the commission fee product, but not the monthly plan and yearly plan and will only show the record with the commission fee product. So basically, it'll display this:

 transac_id     user_id         product
 ----------     -------         -------
  7845946       998741      commission fee
  8897155       166235      commission fee.

Thanks!

asked 28 secs ago

برچسب: نویسنده: استخدام کار تاريخ: پنجشنبه 13 خرداد 1395 ساعت: 8:27

صفحه بندی