I am using SQLite and have a Trans_Date field that is stored as a text field. For various reasons, I want to leave the text values in that column as is. Here is the text format for that trans_date column:
m/d/yyyy h:mm:ss
Now, if I want to filter by a specific date, I can simply type in that string. However, the problem comes when I want to search a date range. The only way I can think of to do this is to filter by a list of date strings:
SELECT *
FROM LS2014
WHERE TRANS_DATE IN
('1/1/2014 0:00:00','1/2/2014 0:00:00','1/3/2014 0:00:00','1/4/2014 0:00:00')
Fortunately, I can create this string rather easily using Python or Excel's text functions, but I would much rather find a better way of doing this. Is there a better method for doing the same thing in SQL/SQLite?