freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Michael Peppler <mpeppler AT peppler.org>
- To: freetds AT lists.ibiblio.org
- Subject: Re: [freetds] managing two DBD::Sybase modules
- Date: 06 Jan 2003 09:56:44 -0800
On Mon, 2003-01-06 at 09:39, Steve Langasek wrote:
> On Mon, Jan 06, 2003 at 12:15:25PM -0500, Lowden, James K wrote:
> > > From: Andrew Stanley [mailto:astanley AT cs.uml.edu]
> > > Sent: January 6, 2003 11:34 AM
> > >
> > > (I hacked DBD::Sybase to look like DBD::FreeTDS, so I could have
> > > 2 different DBD::Sybase's co-existing)
>
> > [musing]
>
> > Several people have mentioned the need to use FreeTDS and Sybase's
> > libraries
> > at the same time in Perl. At present, that's only possible by using
> > DBD::Sybase for Sybase and DBD::ODBC or sybperl for FreeTDS. In limited
> > cases, it may be possible to get away with manipulating @INC to manage two
> > DBD::Sybase modules, but almost no one wants the administration headaches
> > that are sure to follow.
>
> > I wonder if there isn't/couldn't be a better way. For example, could the
> > namespace and module name of DBD::Sybase be altered at configuration time?
> > Could we use Perl namespaces another way, to convert DBD::Sybase into,
> > say,
> > DBD::FreeTDS::Sybase?
>
> > Andrew used hackery. Is no mechanism available to make that unnecessary?
> >
>
> Even if you managed to keep the two modules clear of each other within
> the Perl namespace, there would still be (unavoidable) namespace
> collisions at the C level. If "at the same time in Perl" means "in the
> same process", anything that would make this work would *always* be a
> kludge.
Well, not necessarily. Both DBD::Sybase and Sybase::CTlib can co-exist,
and they use the same functions. By using dynamic loading we should be
able to have DBD::Sybase (with the Sybase libs) and (say) DBD::FreeTDS
(with the freetds libs) in the same process with no problems.
It would be easy enough to test - I could probably whip together a
DBD::FreeTDS module (based on the DBD::Sybase source).
> I think efforts are better directed towards answering the question, "why
> is one set of libraries not sufficient?", and fixing the corresponding
> deficiencies in FreeTDS.
I agree - but maybe some people need a solution for this *now*...
Michael
--
Michael Peppler Data Migrations, Inc.
mpeppler AT peppler.org http://www.mbay.net/~mpeppler
Sybase T-SQL/OpenClient/OpenServer/C/Perl developer available for short or
long term contract positions - http://www.mbay.net/~mpeppler/resume.html
-
[freetds] managing two DBD::Sybase modules,
Lowden, James K, 01/06/2003
-
Re: [freetds] managing two DBD::Sybase modules,
Steve Langasek, 01/06/2003
-
Re: [freetds] managing two DBD::Sybase modules,
Michael Peppler, 01/06/2003
- Re: [freetds] managing two DBD::Sybase modules, Steve Langasek, 01/06/2003
-
Re: [freetds] managing two DBD::Sybase modules,
Michael Peppler, 01/06/2003
- Re: [freetds] managing two DBD::Sybase modules, Andrew Stanley, 01/06/2003
-
Re: [freetds] managing two DBD::Sybase modules,
Steve Langasek, 01/06/2003
Archive powered by MHonArc 2.6.24.