Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2000 > SQL Server 2000
|
SQL Server 2000 General discussion of Microsoft SQL Server -- for topics that don't fit in one of the more specific SQL Server forums. version 2000 only. There's a new forum for SQL Server 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2000 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 15th, 2003, 11:48 AM
Registered User
 
Join Date: Jul 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Closing ADO connections in new page

I am using Crystal Reports and ADO recordsets. I open the connections and pass recordsets from them to the Crystal ActiveX viewer.

Because Crystal is still using the connections I am unable to close the connections within the same page. However if I don't close the connections I have SQL processes left open appearing in the SQL Enterprise Manager's management->Current Activity->Process Info. :(

Therefore I need to close these connections in a separate page (to be called when the user closes the report viewer). Problem is these connection objects will no longer be in scope. (I assume I can't write out client side handles and pass these on - it would surprise me if I could.)

One method would be store the connection objects in session variables. However I know this is bad practice and causes all sorts of scaleability and exclusivity problems. I need to hang onto my ASP session and application data so I can't simply do a session.abandon() either.

How else can I close these connections? Neither SQL nor Crystal seem to close them for me. Do I need to open them in some other manner or is there a means of 'getting' the open connections to a database (in a later ASP page) and then closing them. Or is there a simple handle I can pass on client side to a new page?





Similar Threads
Thread Thread Starter Forum Replies Last Post
Opening & Closing Database connections pauliehaha Classic ASP Databases 4 December 18th, 2006 08:50 AM
closing connections - application pooling goingmad Classic ASP Databases 0 September 29th, 2005 08:20 AM
closing connections - application pooling goingmad SQL Server ASP 0 September 29th, 2005 07:19 AM
Closing db connections - when/how? SoC Classic ASP Basics 11 November 23rd, 2004 05:47 PM
Closing connections when redirecting alldis Classic ASP Basics 3 July 30th, 2003 08:33 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.