Hello friends,
I'm using dbexpsda 3.0 on a Delphi 7 client/server application.
There's only a sqlconnection that remains opened for all the program execution.
My problem is when occurs a network error, for example:
- a switch is restarted.
- a network cable is disconected and after connected.
- etc
These problems causes an error on my opened connection.
There's any component or a tip to help me to resolve this problem?
Best regards
Eder Willian
Lost of connection on newtwork error.
You should reconnect after your connection become broken and then recovered:
Code: Select all
SQLConnection.Active = False;
SQLConnection.Active = True;
Is there a specific error code or exception class to catch and find out, that the connection is actually broken and that's not just a "regular" error like wrong sql code or other kind of exception etc.Antaeus wrote:You should reconnect after your connection become broken and then recovered:Code: Select all
SQLConnection.Active = False; SQLConnection.Active = True;
EDatabaseError does not say much.