Can"t connect to Sybase Rep server

Can"t connect to Sybase Rep server

am 27.02.2006 20:39:36 von matthew.persico

This simple test program:

use strict;
use warnings;
use DBI;
my $dbh =3D DBI->connect('dbi:Sybase:server=3DREPP', 'REPP_login',
'REPP_passwd', {RaiseError =3D> 1});
my $dummy =3D 6;

causes this:

Server message number=3D17001 severity=3D10 state=3D0 line=3D0 server=3DREP=
P
text=3DNo SRV_OPTION handler installed.OpenClient message: LAYER =3D (1)
ORIGIN =3D (1) SEVERITY =3D (1) NUMBER =3D (183)
Server REPP, database
Message String: ct_options(): user api layer: external error: An error
was returned from the server while setting the options, check the
server message for details.
Server message number=3D2056 severity=3D12 state=3D0 line=3D0 server=3DREPP
text=3DLine 1, character 8: Incorrect syntax with 'select'.
persicom@nydux-ast401 (DEV, uid=3D8030(persicom) gid=3D200(develop) depth=
=3D0)

using Perl 5.6.1, DBI 1.48 and DBD::Sybase 1.07.

However, when using Perl 5.6.1, DBI 1.37 and DBD::Sybase 1.00, I get
no error message.

What DBI trace flags/envars do I neet to set in order to diagnose this?

--
Matthew O. Persico

Re: Can"t connect to Sybase Rep server

am 27.02.2006 21:28:29 von manderso

This is not a very helpful answer, but are you sure this is worth
trying? A Replication Server is not an Adaptive Server Enterprise.
Admittedly they both use the same Tabular Data Stream networking
protocol, but they have very different command languages. A Rep Server
isn't even a database server. Are you sure it is reasonable to expect a
DBI driver for Sybase ASE to work correctly with Rep Server?

Maybe Sybperl is the way to go if you want your perl program to talk to
a Rep Server.

Good luck,

Mark

Matthew Persico wrote:

>This simple test program:
>
>use strict;
>use warnings;
>use DBI;
>my $dbh = DBI->connect('dbi:Sybase:server=REPP', 'REPP_login',
>'REPP_passwd', {RaiseError => 1});
>my $dummy = 6;
>
>causes this:
>
>Server message number=17001 severity=10 state=0 line=0 server=REPP
>text=No SRV_OPTION handler installed.OpenClient message: LAYER = (1)
>ORIGIN = (1) SEVERITY = (1) NUMBER = (183)
>Server REPP, database
>Message String: ct_options(): user api layer: external error: An error
>was returned from the server while setting the options, check the
>server message for details.
>Server message number=2056 severity=12 state=0 line=0 server=REPP
>text=Line 1, character 8: Incorrect syntax with 'select'.
>persicom@nydux-ast401 (DEV, uid=8030(persicom) gid=200(develop) depth=0)
>
>using Perl 5.6.1, DBI 1.48 and DBD::Sybase 1.07.
>
>However, when using Perl 5.6.1, DBI 1.37 and DBD::Sybase 1.00, I get
>no error message.
>
>What DBI trace flags/envars do I neet to set in order to diagnose this?
>
>--
>Matthew O. Persico
>
>
>
>

--
Mark Anderson mailto:manderso@asf.alaska.edu
Alaska Satellite Facility phone: (907) 474-5789
Geophysical Institute fax: (907) 474-6441
University of Alaska Fairbanks
903 Koyukuk Dr., PO Box 757320
Fairbanks, Alaska 99775-7320

It's better to ask a stupid question than to make a stupid assumption.

Re: Can"t connect to Sybase Rep server

am 27.02.2006 22:58:55 von matthew.persico

On 2/27/06, Mark Anderson wrote:
> This is not a very helpful answer, but are you sure this is worth
> trying? A Replication Server is not an Adaptive Server Enterprise.
> Admittedly they both use the same Tabular Data Stream networking
> protocol, but they have very different command languages. A Rep Server
> isn't even a database server. Are you sure it is reasonable to expect a
> DBI driver for Sybase ASE to work correctly with Rep Server?

Yes. We have a current production job that does exactly this. The
problem appears to be in our development environment where we updated
the DBI and DBD::Sybase version.

But your point does ring a bell. A rep server is a different beast
than an ASE server. The error message (see below) stated that the
server basically didn't know what to do with "select". I bet that
DBD::Sybase 1.07 is making a call to the database to get some
information that was not made in DBD::Sybase 1.00. That would explain
the problem. I guess a diff of the versions is in order. I'll try it
later tonight unless Michael chimes in with a eureka moment before
then... :-)

>
> Maybe Sybperl is the way to go if you want your perl program to talk to
> a Rep Server.
>
> Good luck,
>
> Mark
>
> Matthew Persico wrote:
>
> >This simple test program:
> >
> >use strict;
> >use warnings;
> >use DBI;
> >my $dbh =3D DBI->connect('dbi:Sybase:server=3DREPP', 'REPP_login',
> >'REPP_passwd', {RaiseError =3D> 1});
> >my $dummy =3D 6;
> >
> >causes this:
> >
> >Server message number=3D17001 severity=3D10 state=3D0 line=3D0 server=3D=
REPP
> >text=3DNo SRV_OPTION handler installed.OpenClient message: LAYER =3D (1)
> >ORIGIN =3D (1) SEVERITY =3D (1) NUMBER =3D (183)
> >Server REPP, database
> >Message String: ct_options(): user api layer: external error: An error
> >was returned from the server while setting the options, check the
> >server message for details.
> >Server message number=3D2056 severity=3D12 state=3D0 line=3D0 server=3DR=
EPP
> >text=3DLine 1, character 8: Incorrect syntax with 'select'.
> >persicom@nydux-ast401 (DEV, uid=3D8030(persicom) gid=3D200(develop) dept=
h=3D0)
> >
> >using Perl 5.6.1, DBI 1.48 and DBD::Sybase 1.07.
> >
> >However, when using Perl 5.6.1, DBI 1.37 and DBD::Sybase 1.00, I get
> >no error message.
> >
> >What DBI trace flags/envars do I neet to set in order to diagnose this?
> >
> >--
> >Matthew O. Persico
> >
> >
> >
> >
>
> --
> Mark Anderson mailto:manderso@asf.alaska.edu
> Alaska Satellite Facility phone: (907) 474-5789
> Geophysical Institute fax: (907) 474-6441
> University of Alaska Fairbanks
> 903 Koyukuk Dr., PO Box 757320
> Fairbanks, Alaska 99775-7320
>
> It's better to ask a stupid question than to make a stupid assumption.
>
>
>


--
Matthew O. Persico

Re: Can"t connect to Sybase Rep server

am 28.02.2006 07:54:07 von michael.peppler

This is a known problem, and has been fixed in either 1.07 or 1.07_01.

DBD::Sybase tries to see if chained transactions are supported at startup,
and tries to find the @@version of the server. Both of these requests fail
against a replication server, but the failure is expected, so should simply
be hidden from the user...

Michael




Extranet
matthew.persico@gmail.com - 27/02/2006 20:39

To: dbi-users, Michael PEPPLER

cc:


Subject: Can't connect to Sybase Rep server


This simple test program:

use strict;
use warnings;
use DBI;
my $dbh = DBI->connect('dbi:Sybase:server=REPP', 'REPP_login',
'REPP_passwd', {RaiseError => 1});
my $dummy = 6;

causes this:

Server message number=17001 severity=10 state=0 line=0 server=REPP
text=No SRV_OPTION handler installed.OpenClient message: LAYER = (1)
ORIGIN = (1) SEVERITY = (1) NUMBER = (183)
Server REPP, database
Message String: ct_options(): user api layer: external error: An error
was returned from the server while setting the options, check the
server message for details.
Server message number=2056 severity=12 state=0 line=0 server=REPP
text=Line 1, character 8: Incorrect syntax with 'select'.
persicom@nydux-ast401 (DEV, uid=8030(persicom) gid=200(develop) depth=0)

using Perl 5.6.1, DBI 1.48 and DBD::Sybase 1.07.

However, when using Perl 5.6.1, DBI 1.37 and DBD::Sybase 1.00, I get
no error message.

What DBI trace flags/envars do I neet to set in order to diagnose this?

--
Matthew O. Persico




This message and any attachments (the "message") is
intended solely for the addressees and is confidential.
If you receive this message in error, please delete it and
immediately notify the sender. Any use not in accord with
its purpose, any dissemination or disclosure, either whole
or partial, is prohibited except formal approval. The internet
can not guarantee the integrity of this message.
BNP PARIBAS (and its subsidiaries) shall (will) not
therefore be liable for the message if modified.

---------------------------------------------

Ce message et toutes les pieces jointes (ci-apres le
"message") sont etablis a l'intention exclusive de ses
destinataires et sont confidentiels. Si vous recevez ce
message par erreur, merci de le detruire et d'en avertir
immediatement l'expediteur. Toute utilisation de ce
message non conforme a sa destination, toute diffusion
ou toute publication, totale ou partielle, est interdite, sauf
autorisation expresse. L'internet ne permettant pas
d'assurer l'integrite de ce message, BNP PARIBAS (et ses
filiales) decline(nt) toute responsabilite au titre de ce
message, dans l'hypothese ou il aurait ete modifie.

Re: Can"t connect to Sybase Rep server

am 01.03.2006 16:59:16 von chuckfox2

One solution would be to install your own error handler and catch the
17001 and 2056 errors and ignore them.

HTH,

Chuck

manderso@asf.alaska.edu wrote:

> This is not a very helpful answer, but are you sure this is worth
> trying? A Replication Server is not an Adaptive Server Enterprise.
> Admittedly they both use the same Tabular Data Stream networking
> protocol, but they have very different command languages. A Rep
> Server isn't even a database server. Are you sure it is reasonable to
> expect a DBI driver for Sybase ASE to work correctly with Rep Server?
>
> Maybe Sybperl is the way to go if you want your perl program to talk
> to a Rep Server.
>
> Good luck,
>
> Mark
>
> Matthew Persico wrote:
>
>> This simple test program:
>>
>> use strict;
>> use warnings;
>> use DBI;
>> my $dbh = DBI->connect('dbi:Sybase:server=REPP', 'REPP_login',
>> 'REPP_passwd', {RaiseError => 1});
>> my $dummy = 6;
>>
>> causes this:
>>
>> Server message number=17001 severity=10 state=0 line=0 server=REPP
>> text=No SRV_OPTION handler installed.OpenClient message: LAYER = (1)
>> ORIGIN = (1) SEVERITY = (1) NUMBER = (183)
>> Server REPP, database
>> Message String: ct_options(): user api layer: external error: An error
>> was returned from the server while setting the options, check the
>> server message for details.
>> Server message number=2056 severity=12 state=0 line=0 server=REPP
>> text=Line 1, character 8: Incorrect syntax with 'select'.
>> persicom@nydux-ast401 (DEV, uid=8030(persicom) gid=200(develop) depth=0)
>>
>> using Perl 5.6.1, DBI 1.48 and DBD::Sybase 1.07.
>>
>> However, when using Perl 5.6.1, DBI 1.37 and DBD::Sybase 1.00, I get
>> no error message.
>>
>> What DBI trace flags/envars do I neet to set in order to diagnose this?
>>
>> --
>> Matthew O. Persico
>>
>>
>>
>>
>

Re: Can"t connect to Sybase Rep server

am 01.03.2006 18:55:58 von matthew.persico

On 3/1/06, Chuck Fox wrote:
> One solution would be to install your own error handler and catch the
> 17001 and 2056 errors and ignore them.

I am hesitant to do this. I prefer to install error handlers to catch
errors that I know I am causing. However, the select that is causing
this problem in inside DBD::Sybase, during the connection phase. If
the protocol changes in a newer version of DBD::Sybase, these errors
could become legit and I wouldn't know. Better to fix at the point of
error; in this case, inside DBD::Sybase.

>
> HTH,
>
> Chuck
>
> manderso@asf.alaska.edu wrote:
>
> > This is not a very helpful answer, but are you sure this is worth
> > trying? A Replication Server is not an Adaptive Server Enterprise.
> > Admittedly they both use the same Tabular Data Stream networking
> > protocol, but they have very different command languages. A Rep
> > Server isn't even a database server. Are you sure it is reasonable to
> > expect a DBI driver for Sybase ASE to work correctly with Rep Server?
> >
> > Maybe Sybperl is the way to go if you want your perl program to talk
> > to a Rep Server.
> >
> > Good luck,
> >
> > Mark
> >
> > Matthew Persico wrote:
> >
> >> This simple test program:
> >>
> >> use strict;
> >> use warnings;
> >> use DBI;
> >> my $dbh =3D DBI->connect('dbi:Sybase:server=3DREPP', 'REPP_login',
> >> 'REPP_passwd', {RaiseError =3D> 1});
> >> my $dummy =3D 6;
> >>
> >> causes this:
> >>
> >> Server message number=3D17001 severity=3D10 state=3D0 line=3D0 server=
=3DREPP
> >> text=3DNo SRV_OPTION handler installed.OpenClient message: LAYER =3D (=
1)
> >> ORIGIN =3D (1) SEVERITY =3D (1) NUMBER =3D (183)
> >> Server REPP, database
> >> Message String: ct_options(): user api layer: external error: An error
> >> was returned from the server while setting the options, check the
> >> server message for details.
> >> Server message number=3D2056 severity=3D12 state=3D0 line=3D0 server=
=3DREPP
> >> text=3DLine 1, character 8: Incorrect syntax with 'select'.
> >> persicom@nydux-ast401 (DEV, uid=3D8030(persicom) gid=3D200(develop) de=
pth=3D0)
> >>
> >> using Perl 5.6.1, DBI 1.48 and DBD::Sybase 1.07.
> >>
> >> However, when using Perl 5.6.1, DBI 1.37 and DBD::Sybase 1.00, I get
> >> no error message.
> >>
> >> What DBI trace flags/envars do I neet to set in order to diagnose this=
?
> >>
> >> --
> >> Matthew O. Persico
> >>
> >>
> >>
> >>
> >
>


--
Matthew O. Persico