Re: Still trying to figure this out

From: Date: Thu, 03 Aug 2000 21:19:19 +0000
Subject: Re: Still trying to figure this out
Groups: php.general 
Request: Send a blank email to php-general+get-10034@lists.php.net to get a copy of this message
> Ok, I almost have this working. > > If I send this command though MySql I get the following: > > mysql> SELECT count(*) from database where column1="Yes"; > +----------+ > | count(*) | > +----------+ > | 77 | > +----------+ > > But if I do this: > > $result1 = mysql_query ("SELECT count(*) from database where > column1='Yes'"); > > print ($result1); > > > The result is only 2. What am I doing wrong? > $result is the IDENTIFIER of the result set you get. For actually manipulating the data you should take a look at the functions: mysql_fetch_row, mysql_fetch_array() and mysql_fetch_object(), all those take as ARGUMENT that $result thingie... HTH, -- Dragos Roua Mirabilis Media, http://www.portal.ro http://www.net-info.ro http://www.analyser.ro http://www.adserver.ro http://www.culinar.ro http://www.cartipostale.ro

« previous php.general (#10034) next »