Michael Peppler
Sybase Consulting
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
Sybase on Linux FAQ
Sybperl FAQ
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: Bernard Harrison <bernard dot harrison at showads dot com dot au>
Subject: Sybperl and Apache's mod_perl for CGI
Date: Jan 31 1999 11:16PM

I am experimenting with Apache's mod_perl for executing perl CGI scripts.
I especially want to access a Sybase database through HTML forms.
Having only just started out at this I am using sybperl the way I have been using
it in the conventional sense. i.e. a script that is compiled, executed and exits from
the perl engine. This is a new area for me.

I find that with the little tests that I have been doing that I accumulate database connections.
as tested with Sybase's sp_who, every time I activate and submit a form.

What I really want to do is reuse the same connection or connections. Presumably I will
acquire at least one connection for each httpd process.

Ideally I would like to design a Perl database Object as a front end for whatever I might want to do
which would persistently manage all database connections.

I don't want  the basic CGI approach of compile-exec-exit for every hit.

I'm not sure what the pros and cons are for other solutions.
Would Perl::DBI be a better option? Or something else alltogether?

For example I tried Micheal's Show.cgi that came with the Sybperl distribution
but running it through mod_perl configured as an Apache::Registry. This accumulated
connections for every submission.

I realise this issue may be off topic for this list. Could someone point me in the right


Database Publishing
Show-Ads Sydney Ph: +61 2 9427 1333
               Fax: +61 2 9428 2104
13 Sirius Road
Lane Cove NSW 2066