Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: ODBC and MS SQL Server 2000 Connection

by peacemaker1820 (Pilgrim)
on Jun 28, 2002 at 21:10 UTC ( [id://178145]=note: print w/replies, xml ) Need Help??


in reply to ODBC and MS SQL Server 2000 Connection

print "HTTP/1.0 200 OK\n";
print "Content-Type: text/html\n\n";
print "<HTML><HEAD><TITLE></TITLE></HEAD>\n";
print "<BODY>\n";

use DBI;
#use DBD::ODBC;
use CGI;

my ( $data_source, $database, $user_id, $password ) = qw( sdp-si.biz SDPSI username password   );
my $DSN = "driver={SQL Server};Server=$data_source;Database=$database;UID=$user_id;PWD=$password";
#Connect the database handle.
$dbh = DBI->connect("DBI:ODBC:$DSN") or die "$DBI::errstr\n";

print "hello there";
#Close connection when finished:
$dbh->disconnect;
print "hello there";
print "</BODY>\n";
print "</HTML>\n";
  • Comment on Re: ODBC and MS SQL Server 2000 Connection

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://178145]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (5)
As of 2024-04-19 14:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found