ccn has asked for the wisdom of the Perl Monks concerning the following question:
I've installed Sybase ASE 15.0.2 Developer's edition on my Ubuntu 8.4 desktop. (32bit) Unfortunately when I try to use placeholders I get segmentation fault.
#!/usr/bin/perl -l -- use strict; use warnings; use DBI; delete $ENV{LANG}; $ENV{SYBASE}='/opt/sybase'; my $dbh = DBI->connect('DBI:Sybase:server=asus','sa','') or die $DBI:: +errstr; print "Let's go!"; print $dbh->selectrow_array(<<'SQL'); select count(*) from syskeys where type = 1 SQL print "And now placeholders!"; print $dbh->selectrow_array(<<'SQL', undef, 1); select count(*) from syskeys where type = ? SQL print "END.";
ccn@asus:~/tmp$ perl sy.pl Let's go! 19 And now placeholders! ct_send(CS_DESCRIBE_INPUT) returned 0 at /usr/lib/perl5/DBD/Sybase.pm +line 124. Segmentation fault ccn@asus:~/tmp$
If I make trace then I get the following just before segfault:
dbd_preparse parameter :p1 () dbd_preparse scanned 1 distinct placeholders syb_st_prepare: ct_dynamic(CS_PREPARE) for DBD1 ct_send(CS_DESCRIBE_INPUT) returned 0 at /usr/lib/perl5/DBD/Sybase.pm +line 124. syb_st_prepare: ct_dynamic(CS_DESCRIBE_INPUT) for DBD1 syb_st_prepare: ct_results(CS_DESCRIBE_INPUT) for DBD1 - restype 4 +051 Segmentation fault
I've googled and found that the problem is more likely in CT-Library. But I do not know how to fix it.
Version of DBD::Sybase installed from Ubuntu repository is 1.00
Update:
Placeholders begin to work after upgrading DBD::Sybase to v1.09
In fact I can't say what action solved the problem. It can be the version upgrade, but I suspect that the module compilation is the deal.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to enable placeholders for Sybase ASE on linux?
by genehack (Beadle) on Nov 22, 2008 at 12:03 UTC | |
by ccn (Vicar) on Nov 22, 2008 at 13:15 UTC | |
|
Re: How to enable placeholders for Sybase ASE on linux?
by bart (Canon) on Nov 22, 2008 at 12:53 UTC | |
|
Re: How to enable placeholders for Sybase ASE on linux? (SOLVED)
by mpeppler (Vicar) on Dec 04, 2008 at 15:19 UTC |