Ordinary views leaked through their statistics
DuckDB's team lists changes that missed the 2.0.0 announcement, from a Python appender to views that hide what they filter out.
2 minBig Data & Vector DBsFresh · 26 Oct
DuckDB released version 2.0.0 last week, a long-term-support release its team calls the biggest feature release so far. The announcement covered the Quack protocol, asynchronous I/O, a first-class VARIANT type, agent mode, a PEG parser and triggers. A follow-up post published this week lists smaller changes that did not make the announcement, and several of them matter more day to day than the headline items.
The one with a security consequence is CREATE SECURE VIEW. Regular views can leak information about their underlying tables through statistics and query plans, for example through the stats() function. On a secure view, stats() returns only uninformative statistics and EXPLAIN ANALYZE shows a single Secure View node instead of the view's query plan, so neither can be used to reconstruct the rows the view filters out. For anyone using views as an access boundary, that closes a channel that was open until now.
The Python client finally gets an appender, the preferred way to insert large numbers of rows, which had been available in clients such as C and C++, Go and Java but not in Python. It collects rows and writes them together in a single operation. The team notes that for data already sitting in a DataFrame or Arrow table, INSERT INTO ... SELECT remains faster.
The command-line client now pretty-prints .schema by default and gains a .manual command that shows a SQL function's signatures, description and examples, along with a .history command. Other additions include SHOW for configuration settings, setting a sequence value, session variables as default parameter values, custom partition paths, writing GeoJSON and options in regexp_extract. Each community extension's page now carries a compatibility matrix showing which DuckDB versions and platforms it supports.
Retold from DuckDB. This is a summary in our own words; follow the link for the original reporting.