Skip to Content.
Sympa Menu

freetds - Re: RH 5.1 make (again)

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Craig Burton <craigb AT ibis.com.au>
  • To: 'TDS Development Group' <freetds AT franklin.oit.unc.edu>
  • Subject: Re: RH 5.1 make (again)
  • Date: Mon, 18 Oct 1999 14:59:12 +1000



Mark Schaal writes:
> > DBI::FreeTDS is a separate implementation done by Craig. It does not
use
> > or require the freetds libraries. I have no idea if Craig is still
working
> > on it or not... There is also Michael Pepplers DBD::Sybase which I have
> > personally used and it works well (within the bounds of what freetds
> > supports). You'll need at least version 0.47 of freetds and version
0.19
> > and up of DBD::Sybase should work.
>
> Craig doesn't really like perl, and he spends his time on the JDBC code
> instead. I wrote up a bare minimum DBD of my own, and based on my
> experience I'd recommend using DBD::Sybase. It's a nice package with
> pretty full feature support and Michael is actively developing it.

>
> Sybperl is....well, I'm not sure what sybperl is or why someone would
> want/need to use it. Maybe someone else could fill this in.

sybperl is a thin wrapper around the Sybase C APIs. It's a lot more
mature than DBI/DBD::Sybase (I've been working on it for 9 years :-)
and it's maybe more natural to use for someone who already knows the

Sybase APIs (or MS's DBlibrary). It's a little more
powerfull/flexible
than DBI, though obviously less portable.

Hmmm... the man page warns me not to use this, and instead says go
to Sybase::DBLib instead.

" The Sybase::Sybperl module is provided to ease porting old
perl4/sybperl
1.x programs to perl5. It is not recommended that this module be used
for
any new project. See the Sybase::DBlib manpage or the Sybase::CTlib
manpage
for alternatives. "

CPAN recons my sybase:: etc is up to date. I had a burl with DBLib :

#!/usr/bin/perl

use Sybase::DBlib;

BEGIN { $ENV{'DBI_USER'}='';
$ENV{'DBI_PASS'}='';
$ENV{'DBI_DSN'}='';
$ENV{'SYBASE'}='/usr/local/freetds';}

$dbh = new Sybase::DBlib 'WWW', 'blah', 203.89.235.41, 'test_app';
$dbh->dbcmd("select * from sysprocesses\n");
$dbh->dbsqlexec;
$dbh->dbresults;
while(@data = $dbh->dbnextrow)
{
print @data."\n";
}

Which barked with

Can't call method "dbcmd" without a package or object reference at
./dbtest2.pl line 10.


Something is obviously awry here... all I want to use this software for
is the following

select max(idchange), dschange from tblchange

insert into tblchange (idchange, dschange) values ($max, $ts)

That's it. It just happens that the DB is a remote SQL7.0 and the client
is Linux Perl.

Just forced reinstall of Sybase, but still are problems: CPAN make gives

PERL_DL_NONLAZY=1 /usr/bin/perl -I.././blib/arch -I.././blib/lib
-I/usr/lib/perl5/i386-linux
/5.00404 -I/usr/lib/perl5 -e 'use Test::Harness qw(&runtests $verbose);
$verbose=0; runtests
@ARGV;' t/*.t
t/bcp...............Can't call method "sql" without a package or object
reference at t/bcp.t
line 49.

I am about to install perl 5.005_03, maybe there is some junk linked
into my perl binary.

Any advice for performing this SQL task would be greatly appreciated...

Best,

CB




Archive powered by MHonArc 2.6.24.

Top of Page