From 01b6bf5bb7307246cb2cca7f1cbc8aba693941cc Mon Sep 17 00:00:00 2001
From: adamdottv <2363879+adamdottv@users.noreply.github.com>
Date: Tue, 13 May 2025 13:08:43 -0500
Subject: chore: refactor db

---
 internal/db/sql/messages.sql | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

(limited to 'internal/db/sql/messages.sql')

diff --git a/internal/db/sql/messages.sql b/internal/db/sql/messages.sql
index 475b23a86..6a3b69f6f 100644
--- a/internal/db/sql/messages.sql
+++ b/internal/db/sql/messages.sql
@@ -21,11 +21,9 @@ INSERT INTO messages (
     session_id,
     role,
     parts,
-    model,
-    created_at,
-    updated_at
+    model
 ) VALUES (
-    ?, ?, ?, ?, ?, strftime('%s', 'now'), strftime('%s', 'now')
+    ?, ?, ?, ?, ?
 )
 RETURNING *;
 
@@ -34,7 +32,7 @@ UPDATE messages
 SET
     parts = ?,
     finished_at = ?,
-    updated_at = strftime('%s', 'now')
+    updated_at = strftime('%Y-%m-%dT%H:%M:%f000Z', 'now')
 WHERE id = ?;
 
 
-- 
cgit v1.2.3

