On Apr 16, 8:08 am, "skieros" <nikos1...@gmail.com> wrote:
> my $dbh = DBI->connect('DBI:mysql:;host=mysql3.freehostia.com' ,
> 'nikkou6', 'tiabhp2r', {RaiseError=>1});
> or
> my $dbh = DBI->connect('DBI:mysql:' 'root', 'tiabhp2r',
> {RaiseError=>1});
>
> Is the above likely to work?
I would expect that when connecting to MySQL without specifying a
database you will connect by default to the "mysql" database (if the
lack of a default database isn't the error; never tried), and I doubt
very highly that your host would allow you in there. You might try
adding a die statement if you don't get a handle so you know what went
wrong and so your code doesn't continue on when it shouldn't:
my $dbh = DBI->connect() or die $DBI::errstr;
Matt
|