Results of 1 - 10 of about 172 for instead (0.003 sec.)
- Window Functions 11792
- DuckDB supports window functions , which can use multiple rows to calculate a value for each row. Window functions are blocking operators , i.e., they require their entire input to be buffered, making them one of the most memory-intensive o
...a non-null value of expr if IGNORE NULLS is set) before the current row within the window frame; if there is no such row, instead return default (which must be of the same type as expr ). Both offset and default are evaluated with respect to the curren...nt row (among rows with a non-null value of expr if IGNORE NULLS is set) within the window frame; if there is no such row, instead return default (which must be of the same type as expr ). Both offset and default are evaluated with respect to the curren...tition rows. If an ORDER BY clause is specified, the distribution is computed within the frame using the provided ordering instead of the frame ordering. | | Return type | DOUBLE | | Example | cume_dist() | dense_rank() | Description | The rank of the c... - https://man.mtool.work/duckdb/2.0/sql/functions/window_functions.html
- Configuration 10387
- DuckDB has a number of configuration options that can be used to change the behavior of the system. The configuration options can be set using either the SET statement or the PRAGMA statement . They can be reset to their original values usi
...approximate_join_order_threshold The minimum number of tables in a join to determine the optimal join order approximately instead of exactly. UBIGINT 12 arrow_large_buffer_size Whether Arrow buffers for strings, blobs, UUIDs and bits should be exported...ayout for LIST columns. BOOLEAN false arrow_output_version Whether strings should be produced by DuckDB in Utf8View format instead of Utf8. VARCHAR 1.0 asof_loop_join_threshold The maximum number of rows we need on the left side of an ASOF join to use a...bles. BOOLEAN false enabled_log_types Sets the list of enabled log types. VARCHAR error_on_division_by_zero Throw an error instead of returning NULL when dividing by zero. BOOLEAN true errors_as_json Output error messages as structured JSON instead of a... - https://man.mtool.work/duckdb/2.0/configuration/overview.html
- Migrating to DuckDB 2.0 10387
- DuckDB 2.0.0 is packed with new features and performance improvements, including query optimization and asynchronous I/O. It also ships a small set of breaking changes, most notably a new default storage format, which DuckDB versions before
...x : x + 1 ). -- disabled by default in v2.0.0 SELECT list_transform([1, 2, 3], x -> x + 1); -- use the Python-style syntax instead SELECT list_transform([1, 2, 3], lambda x : x + 1); If you cannot update your queries yet, you can re-enable the old synta...). Use parentheses to get the old behavior, e.g., (2 * 3)! . X'…' and B'…' literals now produce BLOB and BITSTRING values instead of the VARCHAR strings 'x…' and 'b…' . If you would like to revert to the old parser, use the legacy_parser extension . To...an issue . Division by Zero Integer division ( // ) and modulo ( % ) by zero, e.g., 1 // 0 and 1 % 0 , now throw an error instead of returning NULL : Invalid Input Error: Division by zero in expression (1 // 0). Use TRY(...) to return NULL for this exp... - https://man.mtool.work/duckdb/2.0/operations_manual/migration.html
- PostgreSQL Extension 9915
- The postgres extension allows DuckDB to directly read and write data from a running PostgreSQL database instance. The data can be queried directly from the underlying PostgreSQL database. Data can be loaded from PostgreSQL tables into DuckD
...ncluding your credentials, may appear in the resulting error message. For better security, store credentials using secrets instead, as described in Configuring via Secrets . Deprecated The old postgres_attach function was removed in DuckDB 2.0. Use the...ATTACH statement instead. Configuration The ATTACH command takes as input either a libpq connection string or a PostgreSQL URI . Below are some exa...ith the CONNECT statement . While connected, the remote pushdown optimizer ships queries directly to the PostgreSQL server instead of pulling tables over the wire, and DISCONNECT returns the session to the local database. Settings The extension exposes... - https://man.mtool.work/duckdb/2.0/core_extensions/postgres/overview.html
- SQL Quirks 8510
- Like all programming languages and libraries, DuckDB has its share of idiosyncrasies and inconsistencies. Some are vestiges of our feathered friend's evolution; others are inevitable because we strive to adhere to the SQL Standard and speci
...of examples. Aggregating Empty Groups On empty groups, the aggregate functions sum , list , and string_agg all return NULL instead of 0 , [] and '' , respectively. This is dictated by the SQL Standard and obeyed by all SQL implementations we know. This...order, like all other data types (beware the consequences for greatest / least ). age Function age(x) is current_date - x instead of current_timestamp - x . Another quirk inherited from PostgreSQL. Extract Functions list_extract / map_extract_value ret...nversion is deprecated. By default DuckDB still converts the identifier but logs a warning; use an explicit string literal instead, for example glob('no_such_file.csv') . The behavior is controlled by the table_function_identifier_conversion setting: DE... - https://man.mtool.work/duckdb/2.0/sql/dialect/sql_quirks.html
- Troubleshoot 7723
- Overview This page collects common issues encountered when using the DuckDB Rust client, together with their workarounds. If you run into a problem that is not covered here, search the client's issue tracker on GitHub. Linking against a Sys
...he matching duckdb-shared-libs-linux-amd64.tar.gz or duckdb-shared-libs-linux-arm64.tar.gz archive and set LD_LIBRARY_PATH instead. Let the Build Download a Library Set DUCKDB_DOWNLOAD_LIB=1 and the build script downloads the prebuilt DuckDB library mat...Vcpkg, the build finds it automatically. vcpkg uses static libraries by default; set VCPKGRS_DYNAMIC=1 to link dynamically instead. ICU Extension Missing from the Bundled Build Because crates.io imposes a 10 MB package-size limit, the bundled source of...t basis. When cross-compilation is difficult to set up, link against a prebuilt library for the target with DUCKDB_LIB_DIR instead, as described in Linking against a System Library . Further Reading Rust Client — installation, the bundled feature, and t... - https://man.mtool.work/duckdb/2.0/clients/rust/troubleshoot.html
- Glossary of Terms 7723
- This page contains a glossary of a few common terms used in DuckDB. Terms In-Process Database Management System The DBMS runs in the client application's process instead of running as a separate process, which is common in the traditional c
...s are used when a table name used by a query does not exist in the catalog. These scans can substitute another data source instead of the table. Using replacement scans allows DuckDB to, e.g., seamlessly read Pandas DataFrames or read input data from re... - https://man.mtool.work/duckdb/2.0/guides/glossary.html
- Friendly SQL 7723
- DuckDB offers several advanced SQL features and syntactic sugar to make SQL queries more concise. We refer to these colloquially as “friendly SQL”. Several of these features were first introduced by DuckDB, while some are inspired by other
...thout manually defining a schema. INSERT INTO ... BY NAME : this variant of the INSERT statement allows using column names instead of positions. INSERT OR IGNORE INTO ... : insert the rows that do not result in a conflict due to UNIQUE or PRIMARY KEY co...umns with different expressions in a * expression. UNION BY NAME : perform the UNION operation along the names of columns (instead of relying on positions). Prefix aliases in the SELECT and FROM clauses : write x: 42 instead of 42 AS x for improved read...ong tables. Defining SQL-level variables: SET VARIABLE RESET VARIABLE The $name shorthand for reading variables : write $x instead of getvariable('x') . Organizing the catalog: Nested schemas : create schemas within schemas, e.g., CREATE SCHEMA finance.... - https://man.mtool.work/duckdb/2.0/sql/dialect/friendly_sql.html
- Text Functions 7723
- Text Functions and Operators This section describes functions and operators for examining and manipulating STRING values . Function Description string[index] Extracts a single character using a (1-based) index . string[begin:end] Extracts a
...to be valid UTF-8. If read_text attempts to read a file with invalid UTF-8 an error is thrown suggesting to use read_blob instead. See the read_text guide for more details. regexp_escape(string) Escapes special patterns to turn string into a regular ex...character start up to the end of the string. If optional argument length is set, extracts a substring of length characters instead. Note that a start value of 1 refers to the first character of the string . substring_grapheme(string, start[, length]) Ex...rs start up to the end of the string. If optional argument length is set, extracts a substring of length grapheme clusters instead. Note that a start value of 1 refers to the first character of the string . suffix(string, search_string) Returns true if... - https://man.mtool.work/duckdb/2.0/sql/functions/text.html
- SQLite Extension 7565
- The SQLite extension allows DuckDB to directly read and write data from a SQLite database file. The data can be queried directly from the underlying SQLite tables. Data can be loaded from SQLite tables into DuckDB tables, or vice versa. Ins
...table above: Mismatch Type Error: Invalid type in column "i": column was declared as integer, found "hello" of type "text" instead. This error can be avoided by setting the sqlite_all_varchar option: SET GLOBAL sqlite_all_varchar = true; When set, this...option overrides the type conversion rules described above, and instead always converts the SQLite columns into a VARCHAR column. Note that this setting must be set before sqlite_attach is calle...d. Opening SQLite Databases Directly SQLite databases can also be opened directly and can be used transparently instead of a DuckDB database file. In any client, when connecting, a path to a SQLite database file can be provided and the SQLite... - https://man.mtool.work/duckdb/2.0/core_extensions/sqlite.html
DuckDB 2.0 Documentation / man.mtool.work