filter for hero vs specific opponent

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

filter for hero vs specific opponent

Postby dave2085 » Mon Aug 20, 2012 7:14 am

Is this possible? I'd like some kind of global filter to show only my stats vs particular players (for headsup sng.)

hx fpr help i found one for pt4, but this doesnt work for pt3
dave2085
 
Posts: 187
Joined: Mon Jun 02, 2008 10:41 am

Re: filter for hero vs specific opponent

Postby kraada » Mon Aug 20, 2012 10:13 am

This can be done in PT3's custom reports using the following filter expression:

tourney_holdem_hand_player_statistics.id_hand in (SELECT chps.id_hand from tourney_holdem_hand_player_statistics chps, player p where chps.id_player = p.id_player and p.player_name = 'Player X')
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: filter for hero vs specific opponent

Postby busta_ci » Thu Aug 22, 2013 6:59 pm

Hello,

How to adjust this filter for cashgame ?

I've tried cash_hand_player_statistics.id_hand in (SELECT chps.id_hand from cash_hand_player_statistics chps, player p where chps.id_player = p.id_player and p.player_name = 'Player X')

but it doen't work.

Thank you
busta_ci
 
Posts: 5
Joined: Sun Oct 17, 2010 2:50 pm

Re: filter for hero vs specific opponent

Postby kraada » Fri Aug 23, 2013 7:08 am

That should do it. What are you seeing happen? It should get you all hands Player X was dealt into (note that Player X is case sensitive).
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: filter for hero vs specific opponent

Postby busta_ci » Fri Aug 23, 2013 2:20 pm

kraada wrote:That should do it. What are you seeing happen? It should get you all hands Player X was dealt into (note that Player X is case sensitive).


I have "Expression is NOT valid!"
busta_ci
 
Posts: 5
Joined: Sun Oct 17, 2010 2:50 pm

Re: filter for hero vs specific opponent

Postby kraada » Fri Aug 23, 2013 2:36 pm

Then you mistyped - I just copied in exactly what you pasted and it validates for me. Make sure you don't have an extra carriage return before you start the expression - that can cause it to be parsed as invalid.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: filter for hero vs specific opponent

Postby busta_ci » Fri Aug 23, 2013 3:01 pm

kraada wrote:Then you mistyped - I just copied in exactly what you pasted and it validates for me. Make sure you don't have an extra carriage return before you start the expression - that can cause it to be parsed as invalid.



I've tried to write it without copy/paste and it still doesn't work.

To insert this filter I have to click on filter (blue word) and put the expression in the blank space right ? It should be working with any selected section/report ?
busta_ci
 
Posts: 5
Joined: Sun Oct 17, 2010 2:50 pm

Re: filter for hero vs specific opponent

Postby kraada » Fri Aug 23, 2013 3:43 pm

My apologies, I missed that you were doing this in PT3.

In PT3 it's:

holdem_hand_player_statistics.id_hand in (SELECT chps.id_hand from holdem_hand_player_statistics chps, player p where chps.id_player = p.id_player and p.player_name = 'Player X')
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: filter for hero vs specific opponent

Postby busta_ci » Fri Aug 23, 2013 4:09 pm

It works :)

Thanks for your help.
busta_ci
 
Posts: 5
Joined: Sun Oct 17, 2010 2:50 pm


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

Who is online

Users browsing this forum: No registered users and 7 guests

cron