brash
01-12-2009, 11:52 AM
I'd like to make (or get) a custom report that tells me my winnings by time of day. I've briefly looked at the stickies here to help make custom reports, but I'm not clear on how to do the time of day part. I've hunted around in psql (although all of my experience is in MySql) and I'm not completely clear on which date field I want to use (public.playerhandscashkeycolumns.handtimestamp or public.playerhandscashkeycolumns_hero.handtimestam p or something else?).
My biggest problem, though, is that I need to take whatever the data is for the timestamp and turn it into just the time of day (i.e. hour:minute:second, or probably just the second, as an integer from 0 (00:00:00) to 85399 (23:59:59). I think I handle the range thing as was in one of the examples if I have that.
Should I be attempting this by creating a (or using an existing?) psql function? Is there some way to do it in a report file? Like I said, my psql knowledge is extremely limited (I could connect to the DB and use \d to see table info, but I couldn't even figure out how to use SQL commands on the prompt!)
Finally, one more related question: is it possible to make custom graphs? I didn't see any mention of this, but it would be nice to see this information in graph form as well.
Any help would be appreciated! Thanks!
My biggest problem, though, is that I need to take whatever the data is for the timestamp and turn it into just the time of day (i.e. hour:minute:second, or probably just the second, as an integer from 0 (00:00:00) to 85399 (23:59:59). I think I handle the range thing as was in one of the examples if I have that.
Should I be attempting this by creating a (or using an existing?) psql function? Is there some way to do it in a report file? Like I said, my psql knowledge is extremely limited (I could connect to the DB and use \d to see table info, but I couldn't even figure out how to use SQL commands on the prompt!)
Finally, one more related question: is it possible to make custom graphs? I didn't see any mention of this, but it would be nice to see this information in graph form as well.
Any help would be appreciated! Thanks!