Custom Report Select Players

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

Custom Report Select Players

Postby KillerEV » Wed Sep 29, 2010 7:02 pm

I've created a custom report. Like all PT3 custom reports, it's easy to run the report so that it looks at 1 player (the so-called "Active Player") in a DB or all players in a DB. However, I'm interested in running the report on specific players (for example, I might be interested in looking at 10 commonly encountered opponents in a particular game).

Unless I'm wrong, the only way to do this is to apply filters using the names of the particular players I'm interested in looking at. I've tried filters along the lines of the following:

#Player# = 'PLAYERNAME_1' OR #Player# = 'PLAYERNAME_2' OR #Player# = 'PLAYERNAME_3'

Unfortunately, they don't work. In fact, even the simple #Player# = 'PLAYERNAME_1' doesn't work as I think it should. I don't know if it's something to do with how string matching is handled or if it's some other issue, but I figured I'd post this here instead of asking support...so that the posted answer can help others who are having the same problem.

(By the way, go a little easy on me if I'm missing something obvious. I don't have any experience with SQL other than what I've done with creating custom stats and other custom reports. Learning SQL is one of MANY items on the ever-expanding to-do list)
KillerEV
 
Posts: 2
Joined: Sun Jan 10, 2010 8:47 pm

Re: Custom Report Select Players

Postby WhiteRider » Thu Sep 30, 2010 3:21 am

That sort of filter will work, but only if you add a simple filter too. You can filter for NOT a site you never play, or the specific site you're interested in, or hands since a date before you started playing - any filter which doesn't hide any hands is fine.
I don't know why this is needed but it's in our system to be fixed.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Custom Report Select Players

Postby KillerEV » Thu Sep 30, 2010 3:43 pm

Interesting...I already had a simple filter for the report: Between 5 and 6 players. The simple filter for number of players doesn't activate the workaround you speak of. However, I added an additional simple filter for the site I was interested in. Afterwards, my player-specific filter worked. Odd issue; thanks for your help!
KillerEV
 
Posts: 2
Joined: Sun Jan 10, 2010 8:47 pm


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

Who is online

Users browsing this forum: No registered users and 0 guests