Mysql Recordset help
Can anyone help me sort this out.
This code should spit out only the records that match a URK parameter $courscode but whatever I do it returns every record. I just can't figure out why?
$query_rs_dates = sprintf("SELECT * FROM dates09 UNION SELECT * FROM dates10 WHERE coursecode = '$coursecode' ORDER BY id", GetSQLValueString($colname_rs_dates, "text"));
$rs_dates = mysql_query($query_rs_dates, $con_tyf) or die(mysql_error());
$row_rs_dates = mysql_fetch_assoc($rs_dates);
$totalRows_rs_dates = mysql_num_rows($rs_dates);
Can anyone tell me where I am going wrong.
Cheers
Dave
