I try to get data stored in SQL from specific row from a merged table
this is what I tried so far
<?php
$id = $_GET['id'];
$getdetails = mysql_query("SELECT
scholarship.scholarshipid,
scholarship.scholarshipname,
scholarship.shortdescription,
scholarship.scholarshippicture,
scholarshipdetail.fulldescription,
scholarshipdetail.degreetype,
scholarshipdetail.location,
scholarshipdetail.deadline
FROM scholarship, scholarshipdetail
WHERE scholarship.scholarshipid = scholarshipdetail.scholarshipid AND scholarship.scholarshipid = $id ");
$retval = mysql_query( $getdetails, $conn );
if(! $retval )
{
die('Could not get data: ' . mysql_error());
}
?>
The id is gotten from theurl.php?id=IDNUMBER But it turns out that it could not fetch the data. How can I get a data from a row specified by the ID number in PHP?