From 88cbb3cc9bd1807cbd587118709993f931b08334 Mon Sep 17 00:00:00 2001 From: Eduard Tolosa Date: Sat, 26 Jul 2025 22:24:16 -0500 Subject: [PATCH] (chore): add more database improvements --- functions/__based_init_db.fish | 2 ++ 1 file changed, 2 insertions(+) diff --git a/functions/__based_init_db.fish b/functions/__based_init_db.fish index b342888..d618655 100644 --- a/functions/__based_init_db.fish +++ b/functions/__based_init_db.fish @@ -18,6 +18,8 @@ function __based_init_db CREATE INDEX IF NOT EXISTS idx_log_cmd ON log(cmd); CREATE INDEX IF NOT EXISTS idx_log_path_ts ON log(path, ts); CREATE INDEX IF NOT EXISTS idx_log_path_cmd ON log(path, cmd); + CREATE INDEX IF NOT EXISTS idx_log_counter_ts ON log(counter DESC, ts DESC); + CREATE INDEX IF NOT EXISTS idx_log_cmd_like ON log(cmd COLLATE NOCASE); " echo "Based initialized. You can also import your fish history with 'based import'."