Page 1 of 1

Cannot use hole_cards

PostPosted: Mon Jul 14, 2025 9:16 am
by 4StarGen
I've tried to build a stat based on whether I have info on the hole cards or not, for some reason, when hole_cards is empty the "no cards" isn't triggered. It is a varchar, so should be empty

Code: Select all
string_agg(
    CASE
        WHEN lookup_hole_cards.hole_cards != '' THEN lookup_hole_cards.hole_cards
        WHEN lookup_hole_cards.hole_cards = '' THEN 'no cards'
        ELSE NULL
    END,
    ','
) 

Re: Cannot use hole_cards

PostPosted: Tue Jul 15, 2025 5:44 am
by Flag_Hippo
Can you please provide more details about this custom statistic you are building and what you want as the end result.

Re: Cannot use hole_cards

PostPosted: Tue Jul 15, 2025 5:59 am
by 4StarGen
The end goal is to retrieve the hole cards in some specific spots, I play on Ignition so flg_showdown won't going to help since I can download hands after a day and even if I didn't go to the showdown, the hole_cards field is filled with the correct information

For example
Code: Select all
string_agg(
    CASE
        WHEN -- add condition
        THEN  (cash_hand_player_statistics.amt_p_raise_made / cash_limit.amt_bb) ::double precision::text || ' (' || lookup_hole_cards.hole_cards || ')'
        ELSE NULL
    END,
    ','
) 


This retrieves hole cards correctly ONLY if the hole_cards field is not empty, when it is empty the query failed, or at least the stat doesn't show up nor in the reports or HUD. So I'm trying to detect before whether the field is empty or not

Re: Cannot use hole_cards

PostPosted: Wed Jul 16, 2025 5:41 am
by Flag_Hippo
You can test that hole cards are known with:

Code: Select all
cash_hand_player_statistics.id_holecard > 0

Re: Cannot use hole_cards

PostPosted: Wed Jul 16, 2025 5:56 am
by 4StarGen
Fantastic ty, gonna give it a try in a few hours