RE: [PEAR] Problem connecting to database.

From: Date: Tue, 02 Jul 2002 14:03:18 +0000
Subject: RE: [PEAR] Problem connecting to database.
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-1788@lists.php.net to get a copy of this message
Yes, I select $db_name with mysql_select_db($db_name); and I am able to query the database and retrieve rows using the regular mysql_ functions. -----Original Message----- From: Martin Jansen [mailto:mail@martin-jansen.de] Sent: Tuesday, July 02, 2002 9:35 AM To: Sean Chambers Cc: pear-general@lists.php.net Subject: Re: [PEAR] Problem connecting to database. On Tue, 2 Jul 2002 09:19:09 -0400, Sean Chambers wrote: >I can connect fine using the following: >$conn = mysql_connect($db_host,$db_user,$db_pass); >if (!$conn) { > echo mysql_error(); >} > >But when I attempt to do the following it tells me: DB Error: not found > >$dsn = $db_type.'://'.$db_user.':'.$db_pass.'@'. $db_host >.'/'.$db_name; Does the database named $db_name exist on your system? - Martin

« previous php.pear.general (#1788) next »