I've ben testing whether my databse query handler can detect whether the datase conneciton is still active, and if not, log queries to file until the databse connection becomes active again. Our methods until now have been like those described here:
http://forums.ni.com/t5/LabVIEW/How-do-I-get-a-numeric-reference-to-an-ODBC-connection-to-check/m-p/...
Basically, we store the connection reference in a shif register, and check a property of the connection. If this returns an error, your connection is bad and you try to connect again. I've tested this by putting my Open Connection VI in a loop and then disconnecting the ethernet cable or VPN required to connect to our database, and the response from the property node continues to return a value without error. This is odd.
So, I replaced this check with a query (Select USER() is pretty fast), and the failed query robustly detects the lost connection. But it does thake more time. Any reason why method one doesn't work?
_____________
Creator of the BundleMagic plugin for LabVIEW!