having all-in indicator in a report of cash hands

Forum for users that want to write their own custom queries against the PT database either via the Structured Query Language (SQL) or using the PT3 custom stats/reports interface.

Moderator: Moderators

having all-in indicator in a report of cash hands

Postby marvin » Sat Sep 25, 2010 5:23 am

how can i have a stat (for insert in a report of cash hand) that shows "pf", "f", "t", "r" or " " that shows in each hand if it was all-in (if not, the stat shows " ") and when (if is allin, it shows the street) ?
TY in advance!
marvin
 
Posts: 327
Joined: Tue Jul 08, 2008 10:17 am

Re: having all-in indicator in a report of cash hands

Postby WhiteRider » Sat Sep 25, 2010 7:41 am

The street you went all-in is stored in the database field "holdem_hand_player_statistics.enum_allin", so if you add a column to access that (i.e. the expression is exactly "holdem_hand_player_statistics.enum_allin", but without quotes) then it will have a value 'N' for none, or P, F, T or R.
You can then add a stat to display that value.

Tutorial: Custom Reports and Statistics
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: having all-in indicator in a report of cash hands

Postby marvin » Sat Sep 25, 2010 8:56 am

i have built this column in section HE cash:
allin_indicator
its expression is:
holdem_hand_player_statistics.enum_allin
in the same section, i have built this stat:
AI
its expression is:
if(allin_indicator = N, ' ', allin_indicator)

so if is none, i dont see nothing, if is pf, r, t... i see the Characther. but if i try to save the stat PT3 says not valid. why?
marvin
 
Posts: 327
Joined: Tue Jul 08, 2008 10:17 am

Re: having all-in indicator in a report of cash hands

Postby WhiteRider » Sat Sep 25, 2010 9:15 am

You need to put the N in single quotes:

if(allin_indicator = 'N', ' ', allin_indicator)

I would suggest that you do that in the Format Expression and leave the Value Expression just as:
allin_indicator
..although that doesn't really matter.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: having all-in indicator in a report of cash hands

Postby marvin » Sat Sep 25, 2010 2:17 pm

i use if why i dont want see a ton of N in that report. :lol: :mrgreen:
marvin
 
Posts: 327
Joined: Tue Jul 08, 2008 10:17 am

Re: having all-in indicator in a report of cash hands

Postby WhiteRider » Sat Sep 25, 2010 3:48 pm

No, I understand that, but doing that in the Format Expression will have the same effect (display a space) while still keeping the 'N' value of the stat if you ever need to do any comparisons for instance.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: having all-in indicator in a report of cash hands

Postby marvin » Sun Sep 26, 2010 2:25 am

i hadnt understood your suggest, yes.. it is good, ill do like you say. TY
marvin
 
Posts: 327
Joined: Tue Jul 08, 2008 10:17 am


Return to Custom Stats, Reports, and SQL [Read Only]

Who is online

Users browsing this forum: No registered users and 0 guests