Hi!
>>>>> "Bruce" == Bruce Rhodewalt <[EMAIL PROTECTED]> writes:
Bruce> I'm stuck on what appears to be a permissions problem in Perl.
Bruce> In this code...
Bruce> use Mysql;
Bruce> $hostname = "localhost";
Bruce> $databasename = "aep";
Bruce> $username = "kahuna";
Bruce> $password = "testing";
Bruce> #$dbh = Mysql->connect($host);
Bruce> #$dbh = Mysql->connect($host,$databasename);
Bruce> #$dbh = Mysql->connect($host,$databasename,$username,$password);
Bruce> ...uncommenting the first "$dbh" succeeds. Uncommenting either of the lines
Bruce> that follow (where only one "$dbh" is uncommented at a time), produces this
Bruce> error:
Bruce> Can't connect to local MySQL server at ./getmessages.pl line 15
This isn't a permission problem; The above error message means that
the perl program didn't find any listening mysql server on the port it
tried to use. This 'looks' like a bug in the Mysql perl connect code.
Can you instead try to use the DBI/DBD interface; The mSQL-MySQL
modules only emulates the old Mysql interface so there may be
a bug in the emulation.
$dbh=DBI->connect("MySQL:$host:$databasename", $user, $password) || die "Got error:
'$DBI::errstr' when connecting to MySQL";
Regards,
Monty
-----------------------------------------------------------
Send a mail to [EMAIL PROTECTED] with
unsubscribe mysql [EMAIL PROTECTED]
in the body of the message to unsubscribe from this list.