Help for this page

Select Code to Download


  1. or download this
    #!c:/perl/bin/perl
    
    ...
    {
      print "Handle = $dbh\n";
    }
    
  2. or download this
    DBI Connect:  DBI:ODBC:DRIVER={MS SQL 2005};server=localhost;database=
    +online_labs_qa;UID=xxx;PWD=yyy
    Driver = DBI:ODBC:MySQL
    ...
    Get DBI handle
    DBI connect('DRIVER={MS SQL 2005};server=localhost;database=online_lab
    +s_qa;UID=xxx;PWD=yyy','',...) failed: [Microsoft][ODBC Driver Manager
    +] Data source name not found and no default driver specified (SQL-IM0
    +02)(DBD: db_login/SQLConnect err=-1) at odbc_test.pl line 49
    Could not connect to database: [Microsoft][ODBC Driver Manager] Data s
    +ource name not found and no default driver specified (SQL-IM002)(DBD:
    + db_login/SQLConnecterr=-1) at odbc_test.pl line 49.