I replied to a post recently where the OP was unable to connect to a MySQL database because the DBD module was looking at the wrong socket. (Seems to be the default behaviour ;-)) At the time, I gave two solutions: one was to put a mysql_socket parameter in the connect string, the other was to set $ENV{MYSQL_UNIX_PORT}.
I have to report that I am unable to get the first method to work, more times than not - setting %ENV works every time.
As yet, I have been unable to see any rhyme nor reason for when the parameter method works or not. As I'm dealing with 4 machines, each with 2 different Perl versions, I simply don't have time to perform exhaustive tests. I do know that the parameter method is failing on this machine at this time - Perl 5.10.0 with a fresh Bundle::DBD::mysql installed from the CPAN shell.
Whilst this is not an issue for me - because I can use the %ENV method - it would be nice if anyone can throw any light on this, if for no other reason than a documented method not working.
In reply to YAMSP (Yet Another MySQL Socket Problem) by smiffy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |