by kraada » Sun Jun 12, 2011 10:48 am
Oh, Holdem Cash Hand - I was looking in Player Statistics.
In HCH you need to swap it around to filter on hands not players :oops:
This should do it:
holdem_hand_player_statistics.id_hand in (SELECT holdem_hand_player_statistics.id_hand from player, holdem_hand_player_statistics where player.id_player = holdem_hand_player_statistics.id_player and holdem_hand_player_statistics.flg_vpip GROUP BY holdem_hand_player_statistics.id_hand, player.id_player HAVING (((( (CASE WHEN ( (sum((case when(holdem_hand_player_statistics.id_hand > 0) then 1 else 0 end)))) <> 0 THEN (((sum((case when(holdem_hand_player_statistics.flg_vpip) then 1 else 0 end))) * 1.0 )/( (sum((case when(holdem_hand_player_statistics.id_hand > 0) then 1 else 0 end))))) ELSE 0 END) ) * 100) BETWEEN X AND Y)))