List:MySQL++« Previous MessageNext Message »
From:Paul Martin Date:November 7 2007 5:30pm
Subject:Issues with multi-queries
View as plain text  
I'm having some issues using multi-queries... I'm using a C++ dialog app with MySQL
5.0.19-nt and MySQL++ 2.3.2 on a Windows XP platform.  I have modified the 'multiquery
example' to demonstrate these problems... I cant attach b/c of size limits on this list,
so I guess I can email it seperately (is there a better way?). Here is a summary of the
issues:

1. 'Lost Connection to the MySQL Server'
This seems to happen quite often, and I can make it happen more frequently by limiting the
time between queries.  In my program I have a multi-query with about 50-100 mostly updates
being executed every 3 secs or so.  It will run fine for hours and then I get this
message.  I have added some code to reconnect, which seems to help in most cases but not
all.  I have seen a post about a similar problem on the mailing list.  I have noticed the
same problem with my modded multiquery app, depending on the value I give the 'Sleep'
function.  

2. Memory Leak
I am pretty sure that I have a memory leak as a result of the queries.  I have only viewed
the usage in the Windows Task Manager window and I realize that isn't necessarily
accurate, but my app seems to grow and grow from approx 3.5Mb to over 12Mb in 3 hours. 
I've turned off other things, etc. and it seems to be the db queries causing it. I have
noticed a similar growth with my modded multiquery app.  It is hard to tell for sure as
the usage seems to drop after a while to below its starting level (once only).  I think
this is some sort of WIndows garbage collection.  However the growth starts again and
continues way past the original point it dropped.

TIA for any help.

Paul Martin

Thread
Issues with multi-queriesPaul Martin7 Nov
  • Re: Issues with multi-queriesWarren Young7 Nov
  • Re: Issues with multi-queriesPaul Martin7 Nov
    • Re: Issues with multi-queriesWarren Young7 Nov
  • Re: Issues with multi-queriesPaul Martin8 Nov
    • Re: Issues with multi-queriesWarren Young8 Nov
      • Re: Issues with multi-queriesMaarten Schrijvers8 Nov
  • Re: Issues with multi-queriesPaul Martin8 Nov
    • Re: Issues with multi-queriesWarren Young10 Nov
  • Re: Issues with multi-queriesPaul Martin10 Nov
    • Re: Issues with multi-queriesWarren Young10 Nov
  • RE: Issues with multi-queriesIan Daysh12 Nov
    • Re: Issues with multi-queriesWarren Young13 Nov