I'm a newbie myself, but here's an attempt to solve your problem...try this:
<?
$query = "select fieldName1, fieldName2, fieldName3 from tableName";
$result = mysql_query($db, $query);
while($row = mysql_fetch_object ($result)) {
$var1 = $row->fieldName1;
$var2 = $row->fieldName2;
$var3 = $row->fieldName3;
}
?>
The mysql_fetch_object returns your $result as an object, whose member variables can be accessed according to field name.
Of course, being a newbie, I only see how this can work for one row of result data. If anyone can enlighten me as to how to collect multiple rows, that'd be way cool.
Hope this helped a little...