Tell me more ×  I am trying to make a system that you can
create/edit multiple choice questions along with answers. Now
what I have is a table for questions and a table for answers, a
field in the answers table code:  $qexecute =
mysql_query("SELECT * FROM `questions` WHERE `type`='1'"); $num
= mysql_num_rows($execute);     $quest =
mysql_fetch_assoc($execute);     $aexecute = mysql_query("SELECT
* FROM `answers` WHERE `qid`='$i'");     $num =
$mysql_num_rows($aexecute);     $a =
mysql_fetch_assoc($aexecute);     echo $i . '.' .
$quest['questiontext'] . '<br />' . $a['answertext'];  And for
some reason it outputs nothing.  share|improve this question Are
you sure your qids are numbered from 0 to n-1? –  Gumbo Jan 20
at 16:34 First line defines variable $qexecute and the you run
mysql_num_rows($execute); Notice the missing 'q' in $execute
Maybe a typo but like that it would not work in any case – 
Pankrates Jan 20 at 16:35 People get more and more lazy having
SO at hand :-) –  ring0 Jan 20 at 16:36 So there's