-2

I've developed a program in delphi with firebird 2.5 as the db. In delphi i have been closing the connection once i complete a task at every stage. For example, if i add a record, i would open a record and close the adoquery as well as the adoconnection. I came up with this idea as a solution to connection timeout problems if the switch goes down. i have noticed that both the server and nodes hang if a do this.Is this idea correct of i just have to keep the connection open. please advise

2
  • 1
    Are you using ADO with Delphi+Firebird? You should be using IBX or DBXpress Aug 19, 2011 at 21:56
  • Please edit the question and be more specific. You're talking about problems due to a network failure (switch loses power or something?). I don't think anybody can help you debug problems that are caused by network failures, especially when you're asking a question without any code or technical details. Welcome to Stack Overflow, and all that, but you're going to need to ask more detailed questions to get useful answers here.
    – Warren P
    Aug 19, 2011 at 23:26

2 Answers 2

0

Yes - you should keep connection alive. Use cached updates and Apply/CommitUpdates method. Second of all - try to use ie IBDAC components if you work in unstable network.

0
  1. why you aren't using Transactions?
  2. you can check at whenever if your connection is up by calling adoconnection.connected
  3. please better explain your problem...you are facing connectivity problems during the execution and you want a solution to this? or, you want something else?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.