SQLite Forum

How to convert am/pm time to 24hrs time format
Login
Perhaps convert your data to 24-hour format like this:

UPDATE yourtable
      SET Ts = CASE WHEN Ts LIKE '%PM'
                          THEN datetime(trim(Ts,'PM '), '+12 hours')
                          ELSE datetime(trim(Ts,'AM ') END;

—above is copy paste of a reply by Dr Hipp from 2017–