Connection/Transaction Manager in SQL 2000
Connection/Transaction Manager in SQL 2000Old forum URL: forums.lhotka.net/forums/t/6703.aspx
xal posted on Tuesday, March 31, 2009Hi Rocky!
I've been working on CslaGen for 3.x and I found a small issue. The plan is to use Connection and Transaction Managers, but there's an edge case where they create a problem. Sometimes during a read process (datareader) you need to retrieve additional data (lookups, readonly collections, etc). This is not a huge problem With SQL >= 2005 since they can work with multiple active result sets (provided you set it up correctly), but there's no way to work around it in SQL 2000.
I think a simple solution to the problem would be to add an extra parameter to the GetManager methods so that we can specify a context name (optional, of course).
That way, we can create different contexts with different connections that ultimately use the same connection string.
Would you consider adding something like this?
Blarm replied on Tuesday, March 31, 2009
That's the same problem that I have.
Its very common to have to do additional lookups during a fetch and unless you have MARS with SQL2005 or higher you get the problem. SQL2000 does not even support MARS.
I agree with Andres that it would be a good change to the framework.
Marjon1 replied on Tuesday, March 31, 2009I would like to see this as well. It is very useful in the edge cases when you need it.
The current connection manager class that I implemented myself in 2.x has this and would like to see the same functionality when we (finally) upgrade to 3.x
RockfordLhotka replied on Tuesday, March 31, 2009I'll add this to the wish list, it is a good idea.
Copyright (c) Marimer LLC