Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^3: unable to connect new database in mysql

by cjb (Friar)
on Aug 10, 2011 at 11:41 UTC ( [id://919640]=note: print w/replies, xml ) Need Help??


in reply to Re^2: unable to connect new database in mysql
in thread unable to connect new database in mysql

Is your database sever on the localhost and running on the default port?

What arguments to mysql are you using to connect on the command line?

You might want look at something like:

my $db = 'ram'; my $host = ''; # hostname my $port = ''; # portnumber $dbh = DBI->connect("DBI:mysql:database=$db;host=$host;port=$port",'ro +ot','root') or die "Connection Error: $DBI::errstr\n";

Replies are listed 'Best First'.
Re^4: unable to connect new database in mysql
by rammoorthi (Novice) on Aug 10, 2011 at 12:40 UTC
    Thanks its working fine after adding host and port number.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://919640]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2024-04-16 11:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found