dbi-users  

Re: Cant connect to mysql database !

ron
Wed, 20 Jan 2010 20:11:02 -0800

Hi Pooja

See below.

Quoting "Pooja Sohni" <pso...@google.com>:

Can't connect to data source '' because I can't work out what driver
to use (it
doesn't seem to contain a 'dbi:driver:' prefix and the DBI_DRIVER env
var is not
 set) at reportdw.pl line 463

Below is my db connection string format :

use DBI;
my $mysqlDbh = DBI::connect->
("dbi:mysql:dbname:hostname","username","password") or die

Try (for Postgres) dbname=my_db
or (for MySQL) database=my_db

I /really/ suggest you RTFM.

($DBI::errstr);

Can anyone help me on this.

Thanks
Pooja