var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
I'm missing something her in the formatting of datetime. This query does not fail it just does not return rows which I know exist.
WHERE timestamp BETWEEN 2009-11-15 AND 2009-12-16
One: It's a bad idea to name a column "timestamp" because that's a reserved word. If you have to use it, quote your identifier.
Two: MySQL is reading 2009-11-15 as 2009 minus 11 minus 15, or 1983. So your query is really saying:
MySQL won't warn you when you make a mistake like this. The correct syntax for a date literal, assuming you're using 5.5.
SELECT * FROM patients
WHERE timestamp between 1983 AND 1981
Your code will probably want, depending on what date type you're actually using:
WHERE `TIMESTAMP` BETWEEN date '2009-11-15' AND date '2009-12-16'
Just kick me, your right, the quotes make all the difference!