Your input format is wrong: You need a decimal point, not a colon, between the seconds and the fractional seconds. ``` ▶▶▶ create table foo(datetime text); ▶▶▶ insert into foo values ('2021-07-19 08:43:46.956'),('2021-07-20 10:26:41.357'); ▶▶▶ select julianday(max(datetime))-julianday(min(datetime)) from foo; julianday(max(datetime))-julianday(min(datetime)) ------------------------------------------------- 1.07146297441795 ```