My issue is I have a website that is linking to multiple tables in Oracle. I currently have PHP code that checks user input assigned to a variable to find data in a table, then the oci_fetch_row statement that grabs the row where the data matches. This works fine but I cannot find how to output more than one row from a table if some values are the same?
Currently the one row it grabs is put into a simple HTML table.
Any help in to how to fetch all rows that the data matches and output to table would be appreciated.
My code is:
$userfeedback = "SELECT * FROM ASSET_FEEDBACK WHERE USER_EMAIL = '$userEmail' ORDER BY FEEDBACK_DATE";
$stmt3 = oci_parse($conn, $userfeedback);
if(oci_execute($stmt3))
{
$row=oci_fetch_row($stmt3) ;
print"<h2 id='title'>This Users Feedback</h2>";
"<table border='2'>";
print"<tr><td><p>Feedback ID:</td><td>$row[0]</td></tr>";
print"<tr><td>Asset ID:</td><td>$row[1]</td></tr>";
print"<tr><td>Feedback:</td><td>$row[3]</td></tr>";
print"<tr><td>Date added:</td><td>$row[4]</td></tr>";
print"</table></br>";
}