Hello.
Recently I started to use UniDAC components in Delphi 2010 IDE to develop database applications for video surveillance systems. I wrote a small multithreaded application for connection to database and reading data. Each thread has it's own UniConnection to connect to database and UniQuery to retrieve data. I noticed, that if I establish a connection to Microsoft SQL Server (or to MS SQL Server Express) and while connection not established I cant disconnect it and free TUniConnection and thread.
How can I correctly disconnect and free a UniConnection "instantly" and my connection thread while connection to Microsoft SQL Server is in process?
Decreasing a connection timeout doesnt help.
Thanks.
UniDAC MS SQL Server disconnection
Re: UniDAC MS SQL Server disconnection
Hello,
You cannot call the Disconnect method while executing the Connect method.
Connection break on timeout is implemented at the level of the MS SQL client, and if you encounter difficulties with this functionality, you should contact the developers.
You cannot call the Disconnect method while executing the Connect method.
Connection break on timeout is implemented at the level of the MS SQL client, and if you encounter difficulties with this functionality, you should contact the developers.
Re: UniDAC MS SQL Server disconnection
Is there any other Delphi 2010 components that can disconnect from SQL Server while connection in process?
I tried the same thing using UniDAC and connection to MySQL and that works correctly.
I tried the same thing using UniDAC and connection to MySQL and that works correctly.
Re: UniDAC MS SQL Server disconnection
If I set timeout, for example, to 5 connection does not stops in 5 seconds when server is SQL Server.
Re: UniDAC MS SQL Server disconnection
Hello,
We work with MS SQL Server via the client libraries, therefore we cannot affect the connection process. And we work with MySQL directly - not using client libraries - therefore, in this case, we define the behaviour by ourselves and can affect the process of connection to a DB
We work with MS SQL Server via the client libraries, therefore we cannot affect the connection process. And we work with MySQL directly - not using client libraries - therefore, in this case, we define the behaviour by ourselves and can affect the process of connection to a DB