wxPython GUI update with data from a MySQL database

A

Alina Ghergu

Hi there,

I'm currently developing a GUI for a network monitor. I have to plot
data taken from a MySQL database. For GUI I use wxPython, for plotting
Matplotlib. The plotting has to be realtime, so
I have to query the database periodically. I don't have enough
experience in programming and I would need some advice about the best
approach in this matter.

I tried to solve it using wx.Timer but from time to time MySQL server
doesn't repond to queries. I use one db connection for all my queries.
I also tried a threads approach but because I don't know how to use
them the result was worse.

Any sugestion will be highly apreciated.

Alina
 
K

Krzysztof Stachlewski

Hi,
I have to query the database periodically. I don't have enough
experience in programming and I would need some advice about the best
approach in this matter.

I tried to solve it using wx.Timer but from time to time MySQL server
doesn't repond to queries. I use one db connection for all my queries.

What is the error returned from MySQL when it is not responding to queries?

Stach
 
A

Alina Ghergu

Krzysztof said:
Hi,


What is the error returned from MySQL when it is not responding to queries?

Stach

Hi Stach,

The error is "Lost connection to MySQL server during query".

Alina
 
A

Alina Ghergu

I solved the problem by using a more recent version of MySQLdb,
compatible with MySQL 5.0.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,143
Latest member
SterlingLa
Top