Re: Programming - Best Practice
re:
it's OBVIOUS that Microsoft and you DOTNET _FAGS_ are on the losing
side of this argument.
UNNECESSARY CHANGE IS NOT SEXY
UNNECESSARY CHANGE IS NOT EFFICIENT
UNNECESSARY CHANGE IS NOT ACCEPTABLE
On Feb 16, 2:13 pm, "Chris Mullins [MVP]" <cmull...@yahoo .comwrote:
re:
Be aware that, under the hood, open / close don't actually open or close
database connections. IT's more "Check out from pool", "Check back into
pool". It's up the pool as to when the connections are actually opened and
closed.
database connections. IT's more "Check out from pool", "Check back into
pool". It's up the pool as to when the connections are actually opened and
closed.
it's OBVIOUS that Microsoft and you DOTNET _FAGS_ are on the losing
side of this argument.
UNNECESSARY CHANGE IS NOT SEXY
UNNECESSARY CHANGE IS NOT EFFICIENT
UNNECESSARY CHANGE IS NOT ACCEPTABLE
On Feb 16, 2:13 pm, "Chris Mullins [MVP]" <cmull...@yahoo .comwrote:
I think you misunderstood what the MS-Press books were saying.
>
The opening and closing of ADO.NET connections, along with the implications
this has on the connection pool, can catch people by surprise.
>
The general rule for your code is open / execute / close - this is how best
you're able to work with the connection pool. There's nothing stopping you
from doing other things though - like holding connections open, or any of a
dozen other (bad) things.
>
Be aware that, under the hood, open / close don't actually open or close
database connections. IT's more "Check out from pool", "Check back into
pool". It's up the pool as to when the connections are actually opened and
closed.
>
--
Chris Mullins, MCSD.NET, MCPD:Enterprise , Microsoft C# MVPhttp://www.coversant.c om/blogs/cmullins
>
"PFC Sadr" <pfc_s...@hotma il.comwrote in message
>
news:1171663581 .468393.248680@ a75g2000cwd.goo glegroups.com.. .
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
The opening and closing of ADO.NET connections, along with the implications
this has on the connection pool, can catch people by surprise.
>
The general rule for your code is open / execute / close - this is how best
you're able to work with the connection pool. There's nothing stopping you
from doing other things though - like holding connections open, or any of a
dozen other (bad) things.
>
Be aware that, under the hood, open / close don't actually open or close
database connections. IT's more "Check out from pool", "Check back into
pool". It's up the pool as to when the connections are actually opened and
closed.
>
--
Chris Mullins, MCSD.NET, MCPD:Enterprise , Microsoft C# MVPhttp://www.coversant.c om/blogs/cmullins
>
"PFC Sadr" <pfc_s...@hotma il.comwrote in message
>
news:1171663581 .468393.248680@ a75g2000cwd.goo glegroups.com.. .
>
uh a half dozen MS press books???
uh a half dozen MS press books???
uh a half dozen MS press books???
uh a half dozen MS press books???
uh a half dozen MS press books???
get a spid; get another SPID.
DO THEY MATCH?
because if they do then I'll accept a written apology from Microsoft
and new editions of their books that are CORRECTED.
and new editions of their books that are CORRECTED.
On Feb 16, 1:48 pm, "Brian Gideon" <briangid...@ya hoo.comwrote:
On Feb 16, 3:00 pm, pfc_s...@hotmai l.com wrote:
I didn't think that you could even leave a connection open.
it's one of my biggest complaints about ADO.net; I used to use @@SPID
similiar to sessionID in ASP in order to build some simple apps...
similiar to sessionID in ASP in order to build some simple apps...
but now there is nothing like that in .NET from what I understand
I just don't understand; why do you even need to close a connection if
you can't leave a connection OPEN?
you can't leave a connection OPEN?
like I'm being serious and honest here.
Thanks
Hi,
What made you think you couldn't leave a connection open?
Brian
Comment