OnGame Hand Histories

Questions and discussion about PokerTracker 4 for Windows

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Re: OnGame Hand Histories

Postby tigerjack89 » Thu Feb 28, 2013 6:50 pm

kraada wrote:There isn't a way to directly take a hand note from the HUD but if you have a Hand report up in PT4 that shows hands with that tag you can tag it in the HUD and quickly double click the hand and add a note to it from the replayer with the data he mucked.

Tomorrow I'll give it a try in game, thanks a lot for your help and your patience :)
tigerjack89
 
Posts: 245
Joined: Wed Jun 20, 2012 7:31 am

Re: OnGame Hand Histories

Postby tigerjack89 » Fri Mar 01, 2013 2:09 pm

A little bit uncomfortable tbh, expecially if I mix cash and tourney. But if it's the only solution :)

BTW, is there an SQL command to recall a specific hand history with his note?
tigerjack89
 
Posts: 245
Joined: Wed Jun 20, 2012 7:31 am

Re: OnGame Hand Histories

Postby kraada » Fri Mar 01, 2013 2:30 pm

You could write a custom SQL query to get that data. Exactly what are you looking for?
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: OnGame Hand Histories

Postby tigerjack89 » Fri Mar 01, 2013 2:42 pm

kraada wrote:You could write a custom SQL query to get that data. Exactly what are you looking for?

God, I think I edited the previous post. I hope I haven't edit anything somewhere :D

BTW, I try to combine lookup_tags.id_tag with infos of cash_hand_summary and cash_hand_histories, but I can't find a column that relates an hand to his note :S
What I wanna do is to write an sql code that returns me all the hand histories tagged as "MuckedHands" (as text, but it's a secondary problem); in that way I can try to write a custom program that a)copy the hh to another txt file; 2)adds the note related to the hh in a certain position. If this file are created in an autoimport folder, that's it ... :)
tigerjack89
 
Posts: 245
Joined: Wed Jun 20, 2012 7:31 am

Re: OnGame Hand Histories

Postby kraada » Fri Mar 01, 2013 5:41 pm

This query will get you what you want:

select history from cash_hand_histories where id_hand = (select id_x from tags where id_tag = (select id_tag from lookup_tags where enum_type = 'H' and tag = 'MuckedHands'));

Note that it presumes you use the exact text MuckedHands (and those single quotes are needed). You can change that if you want to add a space or whatever though. You're on your own from here though.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: OnGame Hand Histories

Postby tigerjack89 » Fri Mar 01, 2013 5:53 pm

kraada wrote:This query will get you what you want:

select history from cash_hand_histories where id_hand = (select id_x from tags where id_tag = (select id_tag from lookup_tags where enum_type = 'H' and tag = 'MuckedHands'));

Note that it presumes you use the exact text MuckedHands (and those single quotes are needed). You can change that if you want to add a space or whatever though. You're on your own from here though.

Code: Select all
ERROR:  more than one row returned by a subquery used as an expression


Tried also with
Code: Select all
select history from cash_hand_histories where id_hand = (select id_x from tags where id_tag = (select id_tag from lookup_tags where id_tag = 16));
but I have the same error (16 is the id_tag for MuckedHands of course).
I'll try to modify something now.
Also, in this way I can't see the notes, right? It seems like the notes aren't stored in the database.

PS: Do you think that in the future the opportunity to add notes to hands during the game will be implemented?
tigerjack89
 
Posts: 245
Joined: Wed Jun 20, 2012 7:31 am

Re: OnGame Hand Histories

Postby kraada » Fri Mar 01, 2013 6:26 pm

My fault that should be:

select history from cash_hand_histories where id_hand in (select id_x from tags where id_tag = (select id_tag from lookup_tags where enum_type = 'H' and tag = 'MuckedHands'));

The notes are stored in the database, just in a different table. Tags are separate from notes.

To get all notes on these hands also use this query:

select history, note from cash_hand_histories, notes where notes.enum_type = 'H' and notes.id_x = cash_hand_histories.id_hand and cash_hand_histories.id_hand in (select id_x from tags where id_tag = (select id_tag from lookup_tags where enum_type = 'H' and tag = 'MuckedHands'));
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: OnGame Hand Histories

Postby tigerjack89 » Fri Mar 01, 2013 6:34 pm

kraada wrote:My fault that should be:

select history from cash_hand_histories where id_hand in (select id_x from tags where id_tag = (select id_tag from lookup_tags where enum_type = 'H' and tag = 'MuckedHands'));

The notes are stored in the database, just in a different table. Tags are separate from notes.

To get all notes on these hands also use this query:

select history, note from cash_hand_histories, notes where notes.enum_type = 'H' and notes.id_x = cash_hand_histories.id_hand and cash_hand_histories.id_hand in (select id_x from tags where id_tag = (select id_tag from lookup_tags where enum_type = 'H' and tag = 'MuckedHands'));

Thanks a lot for your precious help, I don't use SQL programming for more than 1 year :)
Tomorrow I'll give a look to your code, but it seems gold :)
tigerjack89
 
Posts: 245
Joined: Wed Jun 20, 2012 7:31 am

Re: OnGame Hand Histories

Postby tigerjack89 » Sat Mar 02, 2013 2:46 am

All the note fields have this text
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
. What does it means?
tigerjack89
 
Posts: 245
Joined: Wed Jun 20, 2012 7:31 am

Re: OnGame Hand Histories

Postby WhiteRider » Sat Mar 02, 2013 5:17 am

Notes are stored as xml to allow formatting.
WhiteRider
Moderator
 
Posts: 54017
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

PreviousNext

Return to PokerTracker 4

Who is online

Users browsing this forum: No registered users and 31 guests

cron