dbTalk Databases Forums  

Re: bad_query exception being thrown when leaving program running

mailing.database.mysql-plusplus mailing.database.mysql-plusplus


Discuss Re: bad_query exception being thrown when leaving program running in the mailing.database.mysql-plusplus forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Warren Young
 
Posts: n/a

Default Re: bad_query exception being thrown when leaving program running - 03-03-2005 , 12:05 AM






Drew Ferraro wrote:
Quote:
I am using MySQL++ as the API to handle the database stuff for my
online RPG. The game has a dedicated server which is left running
24/7. Anyway, I notice that if i leave the server running overnight,
and no one plays or logs in the whole time, when i try to log in the
next day, the server crashes when i try to login (when i do a select
statement). It throws a bad_query exception.
Perhaps the connection has an idle timeout built into it? This is
almost certainly not in MySQL++, but in the C API below it, or on the
server side. Take it up on the main MySQL mailing list.

Quote:
Also, if someone can tell me how to extract usefull information from a
bad_query exception,
See the examples.

--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsu...ie.nctu.edu.tw



Reply With Quote
  #2  
Old   
Drew Ferraro
 
Posts: n/a

Default Re: bad_query exception being thrown when leaving program running - 03-03-2005 , 03:18 PM






Hi everyone,

Thanks for your replies. Earl was correct, and calling ping() has
solved my problem.

By the way, Earl, i set it to ping() once an hour, and left the game
running all night with no one connecting. Everything was fine when i
logged in (and the server ran queries) the next day, so i can say that
you are safe doing it at least once an hour (you could probably go
longer i bet).

--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsu...ie.nctu.edu.tw


Reply With Quote
  #3  
Old   
Earl Miles
 
Posts: n/a

Default Re: bad_query exception being thrown when leaving program running - 03-03-2005 , 03:58 PM



Drew Ferraro wrote:
Quote:
Hi everyone,

Thanks for your replies. Earl was correct, and calling ping() has
solved my problem.
I think I accidentally sent that reply just to you because I keep
forgetting this list (unlike most of my other lists) defaults to
replies-go-to-sender.

Quote:
By the way, Earl, i set it to ping() once an hour, and left the game
running all night with no one connecting. Everything was fine when i
logged in (and the server ran queries) the next day, so i can say that
you are safe doing it at least once an hour (you could probably go
longer i bet).

Cool, thanks for that info!

--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsu...ie.nctu.edu.tw



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.