How can I prevent ADO from creating multiple SPIDs?
Posted
by stusmith
on Stack Overflow
See other posts from Stack Overflow
or by stusmith
Published on 2010-05-19T10:54:44Z
Indexed on
2010/05/19
11:00 UTC
Read the original article
Hit count: 215
I'm working on an application that creates a single ADO connection and keeps it open for the lifetime of the application. I have connection pooling turned off.
(Please ignore the fact that this might not be best practice for the purposes of this question).
If I spawn a new thread and use the exact same ADO connection, it uses a new SPID behind the scenes.
Is there anyway to ensure an ADO connection always uses the same SPID, across all threads?
(For reference the application is VC++ using ADO via COM to SQL Server).
© Stack Overflow or respective owner