summaryrefslogtreecommitdiff
path: root/.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json
diff options
context:
space:
mode:
authorOwen Jacobson <owen@grimoire.ca>2024-10-23 00:31:53 -0400
committerOwen Jacobson <owen@grimoire.ca>2024-10-23 00:42:00 -0400
commit3fab58827017041168a769184469cff3722d6c38 (patch)
tree043b49c36976a1eec8fe4306a1e88d3cc2a27e62 /.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json
parent6f7f4410980edd13c57ad54697ebe99d739fef76 (diff)
Make sure (most) queries avoid table scans.
I've exempted inserts (they never scan in the first place), queries on `event_sequence` (at most one row), and the coalesce()s used for event replay (for now; these are obviously a performance risk area and need addressing). Method: ``` find .sqlx -name 'query-*.json' -exec jq -r '"explain query plan " + .query + ";"' {} + > explain.sql ``` Then go query by query through the resulting file.
Diffstat (limited to '.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json')
-rw-r--r--.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json12
1 files changed, 12 insertions, 0 deletions
diff --git a/.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json b/.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json
new file mode 100644
index 0000000..0c21ec1
--- /dev/null
+++ b/.sqlx/query-e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af.json
@@ -0,0 +1,12 @@
+{
+ "db_name": "SQLite",
+ "query": "\n update message\n set body = ''\n where id = $1\n ",
+ "describe": {
+ "columns": [],
+ "parameters": {
+ "Right": 1
+ },
+ "nullable": []
+ },
+ "hash": "e718f4064cbb3d1b27049450121451dbcf01e8bec8a987b58c699b27b5d737af"
+}