Firebird v 2.5 and delphi hanging
I've developed a program in delphi with firebird 2.5 as the db. In delphi i have been closing the connection onc开发者_C百科e 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
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.
- why you aren't using Transactions?
- you can check at whenever if your connection is up by calling adoconnection.connected
- 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?
精彩评论