Help for this page

Select Code to Download


  1. or download this
    my $dbh=DBI->connect('dbi:mysql:database=foo; host=localhost; mysql_so
    +cket=/var/run/mysqld/mysqld.sock', 'myuser', 'myuserpass');
    
  2. or download this
    $ENV{MYSQL_UNIX_PORT}='/var/run/mysqld/mysqld.sock';
    
    my $dbh=DBI->connect('dbi:mysql:database=foo; host=localhost', 'myuser
    +', 'myuserpass');