Closed zzzeek closed 6 years ago
Original comment by Michael Bayer (Bitbucket: zzzeek, GitHub: zzzeek):
i have tested the latest trunk (1609) with sqlite, mysql, postgres and I get the correct results, heres mysql which it seems is what youre using:
SELECT test.id, test.time
FROM test
WHERE test.time >= %s AND test.time <= %s
[17:25:16,248](2006-06-11) [engine](engine): SELECT test.id, test.time
FROM test
WHERE test.time >= %s AND test.time <= %s
[17:25:16,250](2006-06-11) [engine](engine): [6, 6, 0, 0, 1), datetime.datetime(2006, 6, 8, 23, 59, 59)](datetime.datetime(2006,)
(1L, datetime.datetime(2006, 6, 6, 1, 1, 1))
(2L, datetime.datetime(2006, 6, 7, 2, 2, 2))
(3L, datetime.datetime(2006, 6, 8, 3, 3, 3))
---
SELECT test.id, test.time
FROM test
WHERE test.time BETWEEN %s AND %s
[17:25:16,327](2006-06-11) [engine](engine): SELECT test.id, test.time
FROM test
WHERE test.time BETWEEN %s AND %s
[17:25:16,329](2006-06-11) [engine](engine): [6, 6, 0, 0, 1), datetime.datetime(2006, 6, 8, 23, 59, 59)](datetime.datetime(2006,)
(1L, datetime.datetime(2006, 6, 6, 1, 1, 1))
(2L, datetime.datetime(2006, 6, 7, 2, 2, 2))
(3L, datetime.datetime(2006, 6, 8, 3, 3, 3))
---
I tested MySQL with version 0.2.2 and I get the identical results as you did, so make sure you upgrade to at least revision 1609 from the trunk.
Originally reported by: Anonymous
It seems that there is an another problem with between function; test case is below:
output:
may be it concerns standalone between function too.