SQLite Forum

Serious problems with STORED columns
Login
Of course, this will only work to keep the log entries in order if you only have a maximum of one entry per second.  You should change the dt field to real and the default to (julianday()) and get rid of the check constraint if you want to maintain order for up to one entry per millisecond (or one per tick).