I have set up a development server for myself and partner to access. I installed mysql on two different drives and assigned them different ports(3306 for dev and 3307 for production). I use to have the two databases(dev and Prod) on the same drive and could easily switch between the two from an external perl application by setting the $db parameter to either "wx" or "WxDev". I now have "Dev" on one drive with an instance of MYSQL and "PROD" on another drive. This works fine using SQLYog, I just change the port back and forth between 3306 and 3307. The problem I am having now is that the PERL application I was running does not see the PROD environment "Wx". What do I need to do in the PERL process or has it got something to do with the MYSQL Host Address Parameter? I am completely lost on this one!!! This is the connection string I am using: $DBI->connect("DBI :mysql:$db:$host ",$user,$pass. The connection works fine when $db=WxDev. When I set it to $db=Wx it doesn't make the connection. When using SQLYog I point to the WxDev database on drive E: by changing the port to 3306. By changing it to 3307 I point to the database on drive F:. Somehow I need to do something similar from with the PERL application. Thoughts anyone? I have solved the problem by following the advice of Corion and khen1950fx!! Thanks for all the help!. I should have joined this group years ago!!

In reply to Databas connection issue by LHowell

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.