http://www.perlmonks.org?node_id=593104


in reply to sql connectivity

$DSN probably needs to be a connection string rather than a filename.

For example,

$DSN="Driver={SQL Server};Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;"

See also http://www.connectionstrings.com

See also perldoc Win32::ODBC

NAME Win32::ODBC - ODBC Extension for Win32 SYNOPSIS To use this module, include the following statement at the top of +your script: use Win32::ODBC; Next, create a data connection to your DSN: $Data = new Win32::ODBC("MyDSN"); NOTE: *MyDSN* can be either the *DSN* as defined in the ODBC Administrator, *or* it can be an honest-to-God *DSN Connect String +*. Example: "DSN=My Database;UID=Brown Cow;PWD=Moo;"