Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using DBD-Sybase

Status
Not open for further replies.

zvrcvm

Programmer
Aug 1, 2002
23
MX
I have a perl script on a CentOS Linux server which needs to be connected to a Windows resident MSQL server on another network.

I have installed Freetds, DBD-Sybase and DBI modules for perl and mod_perl for Apache 2.

The problem is that if I run my script from a ssh console it runs and connect without any problem, but if I run the same script from an internet browser, it can not connect to the other server.

This is the connection part of the script:

sub cn {
my $dbh = DBI->connect("dbi:Sybase:server=Server_Name;database=Database_Name", 'username', 'password', {PrintError => 0});
die "Unable for connect to server $DBI::errstr please contact to sistemas\@discovery-internet.com" unless $dbh;
return $dbh;
}

The error I get from the browser is:
Unable for connect to server OpenClient message: LAYER = (0) ORIGIN = (0) SEVERITY = (78) NUMBER = (40)

What can I do?

dan


Masochist: Windows programmer with a smile.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top