Commit Graph

10673 Commits

Author SHA1 Message Date
PThorpe92
340b95aa8b Apply PR review suggestions, add comments to partial indexes 2025-09-20 14:38:50 -04:00
PThorpe92
21f6455190 Fix clippy warnings and tests 2025-09-20 14:38:50 -04:00
PThorpe92
f4258b8b08 Just use raw pointer instead of cloning JoinedTable in emitter 2025-09-20 14:38:49 -04:00
PThorpe92
6d8bf009f1 Add some comments 2025-09-20 14:38:49 -04:00
PThorpe92
67cb59d9a7 Add UPDATE tests for partial index behavior 2025-09-20 14:38:49 -04:00
PThorpe92
2d952feae3 Add DELETE behavior tests for partial indexes 2025-09-20 14:38:49 -04:00
PThorpe92
635273f782 Prevent using a partial index as a scan driver 2025-09-20 14:38:48 -04:00
PThorpe92
4c6917f849 Add testing for partial indexes 2025-09-20 14:38:48 -04:00
PThorpe92
51f970a263 Support partial indexes in INSERT/UPDATE/DELETE 2025-09-20 14:38:48 -04:00
PThorpe92
a0f574d279 Add where_clause expr field to Index 2025-09-20 14:38:47 -04:00
PThorpe92
864d113037 Remove dumb comment 2025-09-20 14:38:47 -04:00
Preston Thorpe
25754cb0e4 Merge 'Pragma busy timeout' from Nikita Sivukhin
Expose busy_timeout added in #3067 as a `PRAGMA busy_timeout=<ms
duration>`
https://www.sqlite.org/pragma.html#pragma_busy_timeout

Reviewed-by: Avinash Sajjanshetty (@avinassh)
Reviewed-by: Pere Diaz Bou <pere-altea@homail.com>

Closes #3224
2025-09-20 14:36:29 -04:00
Avinash Sajjanshetty
0597ea722a Add encryption throughput test 2025-09-20 21:56:58 +05:30
pedrocarlo
0e702fbec2 check FaultyQuery depending tables when shrinking 2025-09-20 12:01:07 -03:00
pedrocarlo
021d5d272a refactor shadowing code to take into account snapshot isolation 2025-09-20 12:01:07 -03:00
pedrocarlo
6b0011f477 in shriking remove unnecessary begin commit queries 2025-09-20 11:52:15 -03:00
pedrocarlo
0293c32616 disable integrity check and indexes when using mvcc 2025-09-20 11:52:15 -03:00
pedrocarlo
850dbc75a2 adjust shrinking to keep previous interactions if there are no depending tables 2025-09-20 11:52:15 -03:00
pedrocarlo
c3cdb0e0fd add begin concurrent before each statement with mvcc 2025-09-20 11:52:15 -03:00
pedrocarlo
13f36880f8 adjust generation code to use the context from the current connection index instead of the whole database 2025-09-20 11:52:15 -03:00
pedrocarlo
c4843d6a6e refactor SimulatorEnv to hold committed tables and separate connection tables for snapshot isolation 2025-09-20 11:52:15 -03:00
pedrocarlo
30538e7898 modify Begin struct 2025-09-20 11:52:15 -03:00
Pavan-Nambi
c9ab268bf5 remove extra checks for int column autoincr 2025-09-20 12:59:14 +05:30
Pavan-Nambi
294db6de2d Prevent sqlite_sequence updates from overwriting last_insert_rowid 2025-09-20 12:36:30 +05:30
Pavan-Nambi
6de280789e revert pager changes 2025-09-20 10:59:16 +05:30
Pavan-Nambi
0de92cd7fb update compat.md that we have memmax 2025-09-20 10:54:59 +05:30
Pavan-Nambi
16072de4f6 use Arc not rc and add auto_increment to window 2025-09-20 10:53:48 +05:30
Samuel Marks
d2cd48d9e4 [sqlite3/tests/compat/mod.rs] Use canonical path to fix temp path on macOS ; rename to resolve binding connascence 2025-09-19 20:40:11 -05:00
Nikita Sivukhin
57e52077be add link to the docs 2025-09-19 16:48:43 +04:00
Nikita Sivukhin
c63c820bb7 add busy_timeout pragma 2025-09-19 16:48:12 +04:00
Preston Thorpe
6b273af7e9 Merge 'translate/optimize: centralize AST/expr traversal' from Preston Thorpe
Previously we were rewriting/traversing the AST in a couple different
places, each of these added kinda ad-hoc as we needed them. This
attempts to do the binding of column references as well as the rewriting
of anonymous `Expr::Variable` -> `__param_N` that we use to maintain the
order of bound variables, also normalizes the Qualified Name's.
Also we previously weren't accepting Variable (or at least they wouldn't
work) in places like `LIMIT ? OFFSET ?`, which this PR adds.
I kinda want to keep refactoring translation a bit, and try to break
plan building up into more easy-to-digest chunks.. but I will resist the
urge right now as it's definitely not high priority pre-beta

Reviewed-by: Jussi Saurio <jussi.saurio@gmail.com>

Closes #3210
2025-09-19 08:03:39 -04:00
Preston Thorpe
20493441e0 Merge 'prevent alter table with materialized views' from Glauber Costa
I don't want to even think about the complexity involved in making sure
that materialized views are still sane after the base table(s) are
altered.

Reviewed-by: Preston Thorpe <preston@turso.tech>

Closes #3223
2025-09-19 08:01:58 -04:00
Pekka Enberg
9dda5a6263 Merge 'bugfix: clear reserved space for a reused page' from Avinash Sajjanshetty
fixes #3184

Closes #3198
2025-09-19 14:16:24 +03:00
Glauber Costa
8300d0390e prevent alter table with materialized views
I don't want to even think about the complexity involved in making sure
that materialized views are still sane after the base table(s) are
altered.
2025-09-19 05:59:46 -05:00
Pekka Enberg
2307cf03be Merge 'core/mvcc: Wrap LogicalLog in RwLock' from Pekka Enberg
Closes #3215
2025-09-19 13:40:40 +03:00
Pekka Enberg
69d4745aa0 Merge 'Support JOINs in DBSP materialized views' from Glauber Costa
This PR introduces the final major operator: the JOIN operator.
Many things need to be fixed before we can properly support them, and we
handle those. In particular, JOINs always generate qualified column
statements, but we were not handling them correctly at all in the
operators. Not a problem for linear circuits, but fatal for JOINs.
The operator.rs file also becomes incredibly complex with not one, but
two stateful operator. So it is now broken apart.

Closes #3207
2025-09-19 13:40:21 +03:00
Jussi Saurio
c5ebb0ef63 Merge 'mvcc: remove unused code related to is_logical_log()' from Jussi Saurio
is always logical log

Closes #3220
2025-09-19 13:31:34 +03:00
Nikita Sivukhin
c24e5219d2 remove log file 2025-09-19 14:24:42 +04:00
Nikita Sivukhin
cfc8728774 fix clippy 2025-09-19 14:15:04 +04:00
Jussi Saurio
6a07d56742 Merge 'Put the unused variable behind a flag as intended' from Avinash Sajjanshetty
I keep getting these warnings and it slightly annoys me:
```rust
warning: unused variable: `overflow_cell_count_before`
    --> core/storage/btree.rs:3634:29
     |
3634 |                         let overflow_cell_count_before = parent_contents.overflow_cells.len();
     |                             ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_overflow_cell_count_before`
     |
     = note: `#[warn(unused_variables)]` on by default

warning: unused variable: `overflow_cell_count_after`
    --> core/storage/btree.rs:3641:29
     |
3641 |                         let overflow_cell_count_after = parent_contents.overflow_cells.len();
     |                             ^^^^^^^^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_overflow_cell_count_after`

```

Reviewed-by: Nikita Sivukhin (@sivukhin)

Closes #3219
2025-09-19 12:58:57 +03:00
Jussi Saurio
ba7ae50eff mvcc: remove unused code related to is_logical_log()
is always logical log
2025-09-19 12:55:27 +03:00
Avinash Sajjanshetty
d5295fb45c Put the unused variable behind a flag as intended 2025-09-19 14:55:02 +05:30
Nikita Sivukhin
7049f3ddae fix clock implementation for OPFS IO 2025-09-19 13:21:00 +04:00
Nikita Sivukhin
bc2dbe9025 fix bug 2025-09-19 13:21:00 +04:00
Nikita Sivukhin
b106220743 main thread in browser can't execute parking - so we use parking lot in spin-lock style for that target 2025-09-19 13:21:00 +04:00
PThorpe92
e1ed12b284 rm claude comment 2025-09-19 05:20:20 -04:00
Nikita Sivukhin
1d3c823c7b wip 2025-09-19 13:19:30 +04:00
Nikita Sivukhin
66de28d84b wip 2025-09-19 13:19:30 +04:00
Nikita Sivukhin
1185298670 fix replay generator 2025-09-19 13:19:30 +04:00
Nikita Sivukhin
e68b642f4f set longPollTimeoutMs from js bindings 2025-09-19 13:19:30 +04:00