Contributed Rake

Experiencing technical difficulties? Think you've found a problem with PokerTracker 3? Report it here.

Moderator: Moderators

Re: Contributed Rake

Postby Wolfskin » Tue Aug 11, 2009 7:06 pm

Is it possible to run this query in pokertracker?
It's contributed rake and not weighted contributed like posted earlier in this thread.

Code: Select all
SELECT hs.amt_rake / COUNT(pd2.amt_bet_p) AS contributed_rake FROM holdem_hand_player_detail pd
JOIN player p ON p.id_player = pd.id_player
JOIN holdem_hand_player_detail pd2 ON pd.id_hand = pd2.id_hand
JOIN player p2 ON p2.id_player = pd2.id_player
JOIN holdem_hand_summary hs ON pd2.id_hand = hs.id_hand
JOIN lookup_sites ls ON ls.id_site = hs.id_site
WHERE p.player_name like '%XXX%'
AND ls.site_name like '%XXX%'
AND pd.amt_bet_p >0
AND pd2.amt_bet_p >0
GROUP BY pd.id_hand, hs.amt_rake, ls.site_name;
Wolfskin
 
Posts: 34
Joined: Wed Feb 13, 2008 9:26 pm

Re: Contributed Rake

Postby WhiteRider » Wed Aug 12, 2009 5:26 am

You can't run queries directly in PT3, but you can use PGAdmin: Start > Programs > Postgres > PGAdmin.
Select your database and click the SQL icon in the toolbar.
WhiteRider
Moderator
 
Posts: 54017
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Contributed Rake

Postby Wolfskin » Wed Aug 12, 2009 9:30 am

Is it possible to make a custom stat out of this query? I was only able to do it in SQL and don't know how to do it in pokertracker 3.
Wolfskin
 
Posts: 34
Joined: Wed Feb 13, 2008 9:26 pm

Re: Contributed Rake

Postby kraada » Wed Aug 12, 2009 10:05 am

Which stat section did you want to have this stat in?
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Contributed Rake

Postby Wolfskin » Wed Aug 12, 2009 11:00 am

It would have to be an individual hand statistic, because it isn't a sum. When I tried to SUM it with a COUNT, SQL gave an error, that aggregate functions won't work.

Are "JOIN" commands possible in pokertracker?
Wolfskin
 
Posts: 34
Joined: Wed Feb 13, 2008 9:26 pm

Re: Contributed Rake

Postby kraada » Wed Aug 12, 2009 11:27 am

You can run individual PostgreSQL queries in the custom reports section (see this post), but not in the custom statistics section.

There is also the option to put it in Holdem Cash Player Statistics so it sums over all hands and isn't for each individual hand; I wasn't sure what you wanted to do with the stat and the way you'd built it for each will vary slightly.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Contributed Rake

Postby Wolfskin » Wed Aug 12, 2009 11:30 am

This would be better, because it gives an integer instead of a real. It's the number of contributing players.

Code: Select all
SELECT COUNT(pd2.amt_bet_p) AS contributing_number_of_players FROM holdem_hand_player_detail pd
JOIN player p ON p.id_player = pd.id_player
JOIN holdem_hand_player_detail pd2 ON pd.id_hand = pd2.id_hand
JOIN player p2 ON p2.id_player = pd2.id_player
JOIN holdem_hand_summary hs ON pd2.id_hand = hs.id_hand
WHERE p.player_name like '%XXX%'
AND pd.amt_bet_p >0
AND pd2.amt_bet_p >0
GROUP BY pd.id_hand;
Wolfskin
 
Posts: 34
Joined: Wed Feb 13, 2008 9:26 pm

Re: Contributed Rake

Postby kraada » Wed Aug 12, 2009 12:37 pm

I'm a bit confused about what you want now so let's try to clarify.

Which do you want?

(a) A stat for individual hands that shows for this hand, the player contributed to the rake.
(b) A stat that shows for an individual player, over all of his hands, how much rake total there has been in pots he contributed to.

I'm not sure what the number of contributing players query would be useful for here, so if there's a (c) please elaborate.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Contributed Rake

Postby Wolfskin » Wed Aug 12, 2009 2:03 pm

kraada wrote:I'm a bit confused about what you want now so let's try to clarify.

Which do you want?

(a) A stat for individual hands that shows for this hand, the player contributed to the rake.

This can already be checked, by using holdem_hand_player_detail.amt_bet_p > 0
kraada wrote:(b) A stat that shows for an individual player, over all of his hands, how much rake total there has been in pots he contributed to.

This can already be done by using sum(if[holdem_hand_player_detail.amt_bet_p >0, holdem_hand_summary.amt_rake, 0])
kraada wrote:I'm not sure what the number of contributing players query would be useful for here, so if there's a (c) please elaborate.

to calculate the contributed rake, which depends on the number of players, that have money in the pot, which is for an individual hand holdem_hand_summary.amt_rake/number_of_contributing_players
when you have the number of contributing players you could calculate the contributed rake, but I guess you would need a new stat, because it requires a join to get the information
but it isn't that important, when it can't be done right now in pokertracker
Wolfskin
 
Posts: 34
Joined: Wed Feb 13, 2008 9:26 pm

Re: Contributed Rake

Postby kraada » Wed Aug 12, 2009 4:39 pm

You can't be perfect about it, as someone could limp/fold but if you use holdem_hand_summary.cnt_players_f that will be all players who reached the flop, which is a pretty good approximation. Also, and it may no longer be this way, but certain sites used to count you as contributing so long as you saw the flop, so that may actually end up being what you want (I know OnGame used to do it that way several years back.)
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

PreviousNext

Return to Technical Support / Bug Reports [Read Only]

Who is online

Users browsing this forum: No registered users and 41 guests

cron
highfalutin