Re: Trying to connext to MySQL with PEAR

From: Date: Thu, 06 Jan 2005 16:31:54 +0000
Subject: Re: Trying to connext to MySQL with PEAR
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-38015@lists.php.net to get a copy of this message
On Thursday 06 January 2005 23:41, Jason Davis wrote: > Hi all I am new to PHP and am trying to connect to mysql for the first > time. In that case I strongly suggest that you at least vaguely familiarise yourself with using the basic PHP-native mysql_*() functions first. Go through the examples in the manual, learn how to: - connect to the server - select a database - perform some simple queries - retrieve the results of the queries - handle errors Whilst doing that you will have also confirmed whether your connection parameters (username/password/hostname/dbname) are correct. > I get activity on the mysql monitor when I run it, What is this monitor? Doesn't it give any clearer indication of what is failing? Because this ... > but get the following error. > DB Error: connect failed ... seems to be an error produced by your Pear DB class and isn't very informative at all. If you do the above and use mysql_error() you'll get a more precise error message. -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * ------------------------------------------ Search the list archives before you post http://marc.theaimsgroup.com/?l=php-db ------------------------------------------ New Year Resolution: Ignore top posted posts

« previous php.db (#38015) next »