Q:

how to keep mysql connection alive from Visual Fox Pro

I have a Visual Fox Pro app wich connets with Mysql database via ODBC. everything is working fine until users stop to work (some minutes) in the forms (but forms are open in the fox pro app) and when they return to work the fox pro app show erros about cursors that were created from MySQL tables, so i guess is a timeout disconnection between the fox pro app and the mysql server.
please help me how can keep the connection alive from fox pro? Do you think Do i ping the mysql all the time (for example each second? or do i set the mysql timeout with a new value? I need to fix this but witout loose performance.

A:

Use SQLSetProp to set the IdleTimeout property for the connection. 0 means indefinite. 
Tamar

