Advertisement
Guest User

Untitled

a guest
May 23rd, 2021
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. SELECT SUM(itm.item_cash_staked - itm.item_cash_won)
  2. FROM item itm
  3. WHERE itm.item_rejection_code_id IS null
  4. AND itm.item_created_on > '2019-08-01 17:38:33.613+01'
  5. AND EXISTS (select *
  6. from product p
  7. where p.product_id = itm.product_id
  8. and p.customer_id = 123456)
  9.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement