I'm doing classified table which have featured ad and normal ad they are mixing up
the web will show latest 4 feature ads order by id then show other ads include featured ads and normal ads order by id but not have 4 ads which ready been show as before, but I don't what to use nested query
I have difficulty to create the list of id first 4 ads then exclude them on next query.. here's example which I did simplified, I cut out all other conditions for easy understanding.
$sql = "SELECT adid,title FROM $t_ads where featured='1'";
$featres = mysql_query($sql) or die(mysql_error().$sql);
.. how to create a string list like this $excludeadid = "1,2,3,5,7";
then
$sqlall = "SELECT adid,title FROM $t_ads where adid not in (".$excludeadid.")" ;
or may be use not exit ? or other way to do it right ? best performance