The following SQL Lite statement in Trac
SELECT
id,
changetime / 1000000 as 'MODIFIED',
strftime('%s',"now") as 'NOW',
((strftime('%s',"now")) - (changetime / 1000000)) as 'DIFF'
FROM ticket
WHERE (CAST(((strftime('%s',"now")) - (changetime / 1000000)) AS NUMERIC) < 86400.0)
results the following output:
"changetime" is a field from Trac (type: int64). What I want to achieve is that all tickets which changetime is within one week are selected. I had heavy problems because changetime is int64 and strftime returns something different. This is why I am dividing by 1000000.
Now I have the problem that the WHERE statement is always false altough as you can see on the screenshot I have tickets where it applies (made screenshot after removing WHERE clause temporarly).
Does anybody know what is going wrong?