I have a table with a timestamp field including these values:
2012-03-12 12:53:34
2012-03-12 12:54:11
2012-03-12 01:02:37
2012-03-12 01:03:04
2012-03-12 01:03:46
My query is the following
SELECT * FROM
(Select MESSAGE_OF_USER,MESSAGE_TIME as time,CONVERSATION_ID
from poem_authors_messages
where (CONVERSATION_ID='2' or CONVERSATION_ID='1') and
MESSAGE_TIME>'2012-03-12 12:53:34'
ORDER BY time DESC) poem_authors_messages
ORDER BY time ASC
Notice the time. It should give me these results
2012-03-12 12:54:11
2012-03-12 01:02:37
2012-03-12 01:03:04
2012-03-12 01:03:46
but instead i get
2012-03-12 12:54:11
why is this happening?
Any help appreciated.
3 of your times are AM and not PM. This means that they’re not greater than your filter time…