Disconnect in multithreading

Forum related to MS SQL Server

Moderators: gto, cipto_kh, EgonHugeist

Post Reply
Delian
Fresh Boarder
Fresh Boarder
Posts: 1
Joined: 18.04.2016, 10:53

Disconnect in multithreading

Post by Delian »

Hi,

I'm using server MS SQL 2014. I have issue with disconnect in multithreading. Connect and disconnect is working with one thread. When disconnect in the second thread, i have exception. I have attached call stack.
MSSQL.png
Exception occurs with codetyphon 5.7 with ZeosLib 7.2.0.41 and Delphi XE7 with ZeosLib 7.1.4-stable.

Exception occurs also in designtime.

Code: Select all

- create empty project
- Add and configure first TZConnection in main form.
- add and configure second TZConnection in main form.
- connect first connection.
- connect second connection.
- disconnect first connection.
- try to disconnect second connection <- Got exception:(
MSSQL2.png
You do not have the required permissions to view the files attached to this post.
marsupilami
Platinum Boarder
Platinum Boarder
Posts: 1935
Joined: 17.01.2011, 14:17

Re: Disconnect in multithreading

Post by marsupilami »

Hello Delian,

please don't use ntwdblib.dll and the mssql driver because the ntwdblib.dll is not supported by Microsoft anymore. Please use FreeTDS or OleDB from Zeos7.3.
With best regards,

Jan
Post Reply