我想从 sqlite 数据库中选择图像和视频在这里我实现了我的查询,但它给了我错误的结果我的当前日期是 2014-07-15 但它为我提供了错误的 2014-07-25 日期结果。
我的查询:
SELECT *
FROM myfiles
WHERE (( Date('2014-07-15') >= startdate
AND Date('2014-07-15') <= enddate )
AND ( strftime('%H:%M:%S', starttime) >= '02:09:50'
OR '02:09:50' <= strftime('%H:%M:%S', endtime ))
AND ( strftime('%H:%M:%S',timer_from) >= '02:09:50'
OR '02:09:50' <= strftime('%H:%M:%S',timer_to ))
OR ( strftime('%H:%M:%S',timer_from) = '00:00:00'
OR '00:00:00' = strftime('%H:%M:%S',timer_to )))
AND ( Tuesday = 1 OR Everyday = 1)
AND download = 1
AND playlist_id = 65
AND user_id='265'
ORDER BY position_id ASC, subposition_id ASC
-> 下载此图片的链接
http://screencast.com/t/yS4SqUDqhe
Mysqlite 原始数据库图片
执行查询后 执行查询图像