PEPPLER.ORG
Michael Peppler
Sybase Consulting
Menu
Home
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
Freeware
Sybperl
Sybase::Simple
DBD::Sybase
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
FAQs
Sybase on Linux FAQ
Sybperl FAQ
Personal
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: Michael Peppler <mpeppler at peppler dot org>
Subject: Re: Close not working like I expect...
Date: May 25 2000 2:10PM

Danckert, Michael J. (CAP, CMC) writes:
 > Here is a stripped down version of a test script that I'm working with.
 > There are 2 different sections of the perl script that set up, open, use a
 > db connection then close it.  The second dblogin or dbuse appear to be
 > causing "Database 'CERTPROPDB' is already open and can only have one user at
 > a time." messages.
 > 
 > I can avoid the already open error if I add an "if ( $dbproc1->DBDEAD )"
 > statement and enclose the second dblogin and dbuse in the if.
 > 
 > Is there anything else that I must do to close the first connection?

undef($dbproc);

should do the trick.

Michael
-- 
Michael Peppler         -||-  Data Migrations Inc.
mpeppler@peppler.org    -||-  http://www.mbay.net/~mpeppler
Int. Sybase User Group  -||-  http://www.isug.com
Sybase on Linux mailing list: ase-linux-list@isug.com