Skip to content

Update embedded SQLite3 to 3.52.0#2798

Merged
DL6ER merged 1 commit intodevelopmentfrom
update/sqlite3_52_0
Mar 7, 2026
Merged

Update embedded SQLite3 to 3.52.0#2798
DL6ER merged 1 commit intodevelopmentfrom
update/sqlite3_52_0

Conversation

@DL6ER
Copy link
Member

@DL6ER DL6ER commented Mar 6, 2026

What does this implement/fix?

CHANGELOG 2026-03-06 (3.52.0)

  1. Fix the WAL-reset database corruption bug.
  2. Enhance ALTER TABLE to permit adding and removing NOT NULL and CHECK constraints.
  3. Add the Query Result Formatter (QRF) library for formatting the results of SQL queries for human readability on a fixed-pitch font screen.
    1. Add the format method to the TCL Interface so that QRF is accessible from TCL.
    2. QRF is used for result formatting in the CLI, resulting in improved display capabilities.
  4. New built-in SQL functions: jsonarrayinsert(), and jsonbarrayinsert().
  5. Renovations to the CLI:
    1. Major enhancements to the .mode command.
    2. Improved result formatting, due to the addition of the QRF extension. For example, numeric values are now right-justified by default in tabular output modes.
    3. The default output mode for interactive CLI sessions now uses QRF to display query results in boxes formed using Unicode box-drawing characters, for improved legibility. Batch CLI sessions use the legacy output format for compatibility.
    4. Bare (unquoted) semicolons at the end of dot-commands are silently ignored. ← Potential incompatibility!
    5. Fix the .testcase and .check commands so that they actually work, and use those commands in scripts that part of the standard SQLite test suite included with the source tree.
    6. Command-line arguments that match *.sql or *.txt and are the names of non-empty files are read and interpreted as scripts of SQL statements and/or dot-commands.
    7. The argument to the ".timer" command can now be "once", to run the timer on only the next SQL statement.
    8. The new "--timeout S" option to the ".progress" dot-command causes SQL statements to interrupt after S seconds.
  6. New C-language interfaces:
    1. sqlite3strtruncate()
    2. sqlite3strfree()
    3. sqlite3carraybind_v2()
    4. Add the SQLITEPREPAREFROMDDL option to sqlite3prepare_v3() which permits virtual table implementations to safely prepare SQL statements that are derived from the database schema.
    5. Added the SQLITEUTF8ZT constant which can be used as the encoding parameter to sqlite3resulttext64() or sqlite3bindtext64() to indicate that the value is UTF-8 encoded and zero terminated.
    6. The SQLITELIMITPARSERDEPTH option is added to sqlite3limit().
    7. The SQLITEDBCONFIGFPDIGITS option is added to sqlite3db_config(). See also item 8b below.
  7. Query planner improvements:
    1. Always use a sort-and-merge algorithm for EXCEPT, INTERSECT, and UNION, since this is almost always faster than using a hash table.
    2. Improvements to join order selection in large multi-way joins on a star schema.
    3. Enhance the EXISTS-to-JOIN optimization so that the inserted JOIN terms are not required to be on the inner-most loops, as long as all dependencies for the EXISTS-to-JOIN loops are in outer loops.
    4. Enhance the omit-noop-join optimization so that it is able to omit a chain of joins that do not affect the output.
    5. Allow queries that use "GROUP BY e1 ORDER BY e2" where e1 and e2 are identical apart from ASC/DESC sort-orders to be optimized using a single index.
    6. Allow virtual tables to optimize DISTINCT in cases where the result-set of a query does not exactly match the ORDER BY clause.
  8. Improvements to floating-point ↔ text conversions.
    1. Reimplemented to improve performance.
    2. Rounding is now done by default to 17 significant digits, instead of 15, as was the case for all prior versions. The sqlite3dbconfig(SQLITEDBCONFIGFP_DIGITS) API (item 6g above) can change this, if desired.
  9. The body of TEMP triggers may now modify and/or query tables in the main schema.
  10. Enhance VACUUM INTO so that if a URI filename is used as the target and that filename has a reserve=N query parameter with N between 0 and 255, then the reserve amount for the generated database copy is set to N.
  11. Add the "-p|--port" option to sqlite3_rsync.
  12. Discontinue support for Windows RT.

Related issue or feature (if applicable): N/A

Pull request in docs with documentation (if applicable): N/A


By submitting this pull request, I confirm the following:

  1. I have read and understood the contributors guide, as well as this entire template. I understand which branch to base my commits and Pull Requests against.
  2. I have commented my proposed changes within the code.
  3. I am willing to help maintain this change if there are issues with it later.
  4. It is compatible with the EUPL 1.2 license
  5. I have squashed any insignificant commits. (git rebase)

Checklist:

  • The code change is tested and works locally.
  • I based my code and PRs against the repositories development branch.
  • I signed off all commits. Pi-hole enforces the DCO for all contributions
  • I signed all my commits. Pi-hole requires signatures to verify authorship
  • I have read the above and my PR is ready for review.

Signed-off-by: Dominik <dl6er@dl6er.de>
@DL6ER DL6ER requested a review from a team as a code owner March 6, 2026 19:35
@DL6ER DL6ER added the SQLite3 label Mar 6, 2026
Copy link
Member

@rdwebdesign rdwebdesign left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved (except for the RISCV64 test failure).

@DL6ER
Copy link
Member Author

DL6ER commented Mar 7, 2026

Restarting the test fixed it

@DL6ER DL6ER merged commit b4fe55d into development Mar 7, 2026
24 of 25 checks passed
@DL6ER DL6ER deleted the update/sqlite3_52_0 branch March 7, 2026 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants