subsecond
Applies the subsecond modifier to a date/time value, enabling fractional second precision.
This modifier is an alias for 'subsec' and behaves identically. It instructs SQLite's date and time functions to process the fractional part of seconds when performing calculations. For this to work correctly, it must appear after all other time-modifying clauses (+N days, +N hours, etc.).
When used, subsecond ensures that any fractional seconds from the original time string are preserved through the calculations. This behavior was introduced in SQLite version 3.22.0.
Example
// Add 5 seconds while preserving fractional seconds
select(DATETIME("2024-07-15 10:20:30.500").seconds(5).subsecond()).execute()Content copied to clipboard
Return
A KQLiteColumn with the 'subsecond' modifier applied.
Author
MOHAMMAD AZIM ANSARI