Report identifying sitting out hands

Discuss how to create custom stats, reports and HUD profiles and share your creations.

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Report identifying sitting out hands

Postby afteRReset » Thu Sep 21, 2023 5:44 pm

Is there a way to filter pokerstars sitout hands?
Here's one sample of a hand

Spoiler: show
PokerStars Hand #24610111329: Tournament #36482675, $9.59+$0.41 USD Hold'em No Limit - Level VII (60/120) - 2023/09/21 16:33:35 ET
Table '3648203675 1' 6-max Seat #4 is the button
Seat 4: player (2356 in chips)
Seat 6: player (644 in chips) is sitting out
player: posts the ante 12
player: posts the ante 12
player: posts small blind 60
player: posts big blind 120
*** HOLE CARDS ***
Dealt to player [Js 3d]
player: raises 120 to 240
player: folds
Uncalled bet (120) returned to player
player collected 264 from pot
player: doesn't show hand
*** SUMMARY ***
Total pot 264 | Rake 0
Seat 4: player (button) (small blind) collected (264)
Seat 6: player (big blind) folded before Flop
afteRReset
 
Posts: 49
Joined: Thu Jun 13, 2013 9:11 am

Re: Report identifying sitting out hands

Postby Flag_Hippo » Fri Sep 22, 2023 5:45 am

That information isn't stored in the database so there isn't a built-in filter but you can use a custom filter to search for specific text in the hand history - see this thread. The example is for hands run twice but the principle is the same.
Flag_Hippo
Moderator
 
Posts: 15127
Joined: Tue Jan 31, 2012 7:50 am

Re: Report identifying sitting out hands

Postby afteRReset » Sat Sep 23, 2023 6:04 am

Flag_Hippo wrote:That information isn't stored in the database so there isn't a built-in filter but you can use a custom filter to search for specific text in the hand history - see this thread. The example is for hands run twice but the principle is the same.


Thank you. Could you please suggest what tournament hand alternative would look like? Or where could I look for those tables and columns for tournaments in pt4 database

Code: Select all
cash_hand_histories.id_hand = cash_hand_player_statistics.id_hand
and cash_hand_histories.history like '%Hand was run twice%'
afteRReset
 
Posts: 49
Joined: Thu Jun 13, 2013 9:11 am

Re: Report identifying sitting out hands

Postby Flag_Hippo » Sat Sep 23, 2023 12:13 pm

Substitute cash with tourney and replace Hand was run twice with the text you want to search for:

Code: Select all
tourney_hand_histories.id_hand = tourney_hand_player_statistics.id_hand and tourney_hand_histories.history like '%is sitting out%'

Bear in mind that this filter isn't player specific. If you want something player specific you will need to include the player name and wildcard the possible variations in the chip value length that can be between the player name text and the sitting out text. For more information on pattern matching in PostgreSQL see this guide.
Flag_Hippo
Moderator
 
Posts: 15127
Joined: Tue Jan 31, 2012 7:50 am

Re: Report identifying sitting out hands

Postby afteRReset » Sat Sep 23, 2023 5:57 pm

Flag_Hippo wrote:Substitute cash with tourney and replace Hand was run twice with the text you want to search for:

Code: Select all
tourney_hand_histories.id_hand = tourney_hand_player_statistics.id_hand and tourney_hand_histories.history like '%is sitting out%'

Bear in mind that this filter isn't player specific. If you want something player specific you will need to include the player name and wildcard the possible variations in the chip value length that can be between the player name text and the sitting out text. For more information on pattern matching in PostgreSQL see this guide.


It would be 4 characters max, as I play sngs and stack doesn't get more than 3000. I am not very regex-savy, how do I limit the amount of characters beetween two texts? Needs to be something like this
Code: Select all
 '%Player%{1,4}in chips) is sitting out%'
but it doesn't really work, something wrong with syntax
So far without limitation this works semi-fine but includes some other players sitting out
Code: Select all
tourney_hand_histories.id_hand = tourney_hand_player_statistics.id_hand and tourney_hand_histories.history like '%Player%in chips) is sitting out%'
afteRReset
 
Posts: 49
Joined: Thu Jun 13, 2013 9:11 am

Re: Report identifying sitting out hands

Postby Flag_Hippo » Sun Sep 24, 2023 5:17 am

You can use underscores as a wildcard for any character:

Code: Select all
tourney_hand_histories.id_hand = tourney_hand_player_statistics.id_hand and (tourney_hand_histories.history like '%afteRReset (___ in chips) is sitting out%' or tourney_hand_histories.history like '%afteRReset (____ in chips) is sitting out%')
Flag_Hippo
Moderator
 
Posts: 15127
Joined: Tue Jan 31, 2012 7:50 am

Re: Report identifying sitting out hands

Postby WhiteRider » Mon Sep 25, 2023 4:07 am

This is an alternative that will work for any number between 1 and 4 digits:
Code: Select all
tourney_hand_histories.id_hand = tourney_hand_player_statistics.id_hand and tourney_hand_histories.history SIMILAR TO '%\(\d{1,4} in chips\) is sitting%'

\d is any digit, but you could use _ for any single character too.
Note that we use "similar to" instead of "like" for full regex queries.
WhiteRider
Moderator
 
Posts: 54017
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK


Return to Custom Stats, Reports and HUD Profiles

Who is online

Users browsing this forum: No registered users and 14 guests

cron
highfalutin