I think I’m close, but something isn’t quite right. I really miss being able to use “”. Things were simpler!
Anyway, I’m building a list of DATES from one query:
[php] while($mydates = mysql_fetch_array($gd)) {
$ddates = $ddates.’,’’.$mydates[‘startdate’].’’’; }[/php]
If I echo $ddates, I’m seeing what I think I’m should be seeing:
‘2010-01-01’,‘2013-01-05’,‘2013-01-06’
In my second query, I need to EXCLUDE this list of dates from the result, so I’ve got this:
[php]…AND startdate NOT IN ($ddates)[/php]
Ain’t working. However, if I take the $ddates echo output and place that in the query instead:
[php]…AND startdate NOT IN (‘2010-01-01’,‘2013-01-05’,‘2013-01-06’)[/php]
This DOES work.
What am I missing?
TIA