03292005 1506 GMT-6

Ok. This might be a odd question to some but, in my learning of the user 
of php with mysql, this is how I learned to get values...

$sql = "SELECT x FROM tablename WHERE a = '".$a."'";
    $result = mysql_query($sql);
       while ($row = mysql_fetch_array($result) ) {
          $x = $row['x'];
       }

What I want to know is, if I am just getting ONE result back, can I 
write this differently? I have used this for so long to get all results 
that I never thought to ask.

Wade


[Non-text portions of this message have been removed]



The PHP_mySQL group is dedicated to learn more about the PHP_mySQL web database 
possibilities through group learning.  
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php_mysql/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to