in reply to Re: Centralized DSN Switch Script (MySQL)
in thread Centralized DSN Switch Script (MySQL)

sites-dev - the full path would be something like "/home/sites-dev/site3/web/cgi-bin/script.pl" - that would be a script that runs on the development server.

A production server script would be in the path "/home/sites/site3/web/cgi-bin/script.pl".

It looks like the DSN is coming through fine (I commented out that 'my ($dsn)' line and in the script that required this central script, printed out $dsn.

I'm sure there are other configuration questions, too, but don't know where to start.

Thanks!

  • Comment on Re: Re: Centralized DSN Switch Script (MySQL)

Replies are listed 'Best First'.
Re: Re: Re: Centralized DSN Switch Script (MySQL)
by lucs (Sexton) on Nov 02, 2001 at 03:05 UTC
    Okay. Thought it might have been a typo :-) So, your tests show that in the development environment, $dsn expands to DBI:mysql:database=foo;port=3308 (which is what you seem to want), yet the wrong database is being updated. If that is correct, I don't know what's wrong; the perl up to here is fine. Sorry.
      At least I'm not alone then in my bogglement. ;) I was thinking that maybe it has something to do in the DBD/DBI layer. Oh man, I'm gonna lose some more hair over this one...

      Thanks, lucs