<?php
$sql=mysql_query("SELECT * FROM table_one INNER JOIN table_two ON table_one.id = table_two.field_id ORDER BY table_one.id ASC LIMIT 0 , 300");
$rowCount=mysql_num_rows($sql);
while($row=mysql_fetch_array($sql)){
if($rowCount < 1 || $rowCount=="0" || $rowCount == 0 || $rowCount == NULL || $rowCount == false){
echo "no information retrieved";
}
else{
echo "information retrieved";
}
}
?>
So when setting the condition in the if-else statement I tried several ways to catch the $rowCount value of 0 but it just doesn't seem to work for me.
Does my query need to be using syntax that eliminates null joins or how do I identify when $rowCount = 0 ?