NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
DBD::ODBC (Score:3, Informative)
We use DBD::ODBC and have been very happy. We connect like this (took me a while to work out so hope this helps...)
my $dsn = join "", (
"dbi:ODBC:",
"Driver={SQL Server};",
"Server=gort;",
"UID=gpd;",
"PWD=gpd;",
"Database=gort_db",
);
my $user = 'gpd';
my $passwd = 'gpd';
my $db_options = {
PrintError => 1,
RaiseError => 1,
AutoCommit => 0, #Use transactions
};
my $dbh =
DBI->connect($dsn, $user, $passwd, $db_options)
Re:DBD::ODBC (Score:2)
Thanks for the help, and even more for the sample code! You'll probably find pudge's wonderful ecode tag will help you out.
J. David works really hard, has a passion for writing good software, and knows many of the world's best Perl programmers
Reply to This
Parent