05-21-2008 08:09 PM
05-22-2008 01:35 AM
I don't know how "efficient" it is, but it certainly works.
A better variation is encapsulating the reference getting mechanism. For example, I use an action engine for obtaining the reference in all the VIs. When it is asked for the reference, it first checks to see that the reference actually works and if it doesn't, it goes automatically to its Open action and attempts to reopen the connection a couple of times using the settings it was originally given. The advantage here is that if the connection is lost, it will be renewed automatically, as well as hiding all the DB interaction inside the DB VIs.