Results of 1 - 10 of about 86 for Use case (0.002 sec.)
use (324), case (97)
- Keywords and Identifiers 17962
- Identifiers Similarly to other SQL dialects and programming languages, identifiers in DuckDB's SQL are subject to several rules. Unquoted identifiers need to conform to a number of rules: They must not be a reserved keyword (see duckdb_keyw
...luding tabs and newline characters). Identifiers can be quoted using double-quote characters ( " ). Quoted identifiers can use any keyword, whitespace or special character, e.g., "SELECT" and " § ? ¶ " are valid identifiers. Double quotes can be esc...aped by repeating the quote character, e.g., to create an identifier named IDENTIFIER "X" , use "IDENTIFIER ""X""" . New As of DuckDB 2.0, identifiers can also be quoted using backtick characters ( ` ), following exact...A backtick is escaped by doubling it, e.g., `a b `` denotes the identifier `` a b `. Backtick-quoted identifiers are never case-folded and work everywhere double-quoted identifiers do. Note that stored and round-tripped DDL (for example in [ duckdb_v... - https://man.mtool.work/duckdb/2.0/sql/dialect/keywords_and_identifiers.html
- PostgreSQL Compatibility 17326
- DuckDB's SQL dialect closely follows the conventions of the PostgreSQL dialect. The few exceptions to this are listed on this page. Floating-Point Arithmetic DuckDB and PostgreSQL handle floating-point arithmetic differently for division by
...loat division: SELECT 1 / 2 AS x; PostgreSQL returns 0 , while DuckDB returns 0.5 . To perform integer division in DuckDB, use the // operator: SELECT 1 // 2 AS x; This returns 0 . UNION of Boolean and Integer Values The following query fails in Pos...1 error true '1.1' = 1.1 true true 1 = 1.1 false false true = 'true' true true true = 1 error true 'true' = 1 error error Case Sensitivity for Quoted Identifiers PostgreSQL is case-insensitive. The way PostgreSQL achieves case insensitivity is by lo...wercasing unquoted identifiers within SQL, whereas quoting preserves case, e.g., the following command creates a table named mytable but tries to query for MyTaBLe because quotes preserve the case... - https://man.mtool.work/duckdb/2.0/sql/dialect/postgresql_compatibility.html
- USE Statement 16133
- The USE statement selects a database and optional schema, or just a schema to use as the default. Examples --- Sets the 'memory' database as the default. Will use 'main' schema implicitly or error --- if it does not exist. USE memory; --- S
...ets the 'duck.main' database and schema as the default USE duck.main; -- Sets the `main` schema of the currently selected database as the default, in this case 'duck.main' USE main;...Syntax The USE statement sets a default database, schema or database/schema combination to use for future operations. For instance, table... - https://man.mtool.work/duckdb/2.0/sql/statements/use.html
- PostgreSQL Extension 13696
- 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
...ementation details and background. Installing and Loading The postgres extension will be transparently autoloaded on first use from the official extension repository. If you would like to install and load it manually, run: INSTALL AND LOAD postgres;...Connecting To make a PostgreSQL database accessible to DuckDB, use the ATTACH command with the postgres or postgres_scanner type. To connect to the public schema of the PostgreSQL instance...PostgreSQL instance, such as new columns being added to a table, the cached schema information might be outdated. In this case, the function postgres_clear_cache can be executed to clear the internal caches. CALL postgres_clear_cache(); In version 1... - https://man.mtool.work/duckdb/2.0/core_extensions/postgres/overview.html
- COPY Statement 13693
- Examples Read a CSV file into the lineitem table, using auto-detected CSV options: COPY lineitem FROM 'lineitem.csv'; Read a CSV file into the lineitem table, using manually specified CSV options: COPY lineitem FROM 'lineitem.csv' (DELIMITE
...s data into DuckDB from an external file. COPY ... TO writes data from DuckDB to an external file. The COPY command can be used for CSV , PARQUET and JSON files. COPY ... FROM COPY ... FROM imports data from an external file into an existing table....unt of columns in the table tbl , and the contents of the columns must be convertible to the column types of the table. In case this is not possible, an error will be thrown. If a list of columns is specified, COPY will only copy the data in the spec...lineitem.json into the lineitem table: COPY lineitem FROM 'lineitem.json' (FORMAT json, ARRAY true); An expression may be used as the source of a COPY ... FROM command if it is placed within parentheses. Read the contents of a file whose path is st... - https://man.mtool.work/duckdb/2.0/sql/statements/copy.html
- Securing DuckDB 13517
- DuckDB is a powerful analytical database engine. It can read and write files, access the network, load extensions, and use system resources. Like any powerful tool, these capabilities require appropriate configuration when working with sens
...nments. This page documents DuckDB's security model and security-related settings. The right configuration depends on your use case, environment, and threat model. If you plan to embed DuckDB in your application, also consult the "Embedding DuckDB".... Do not execute SQL from untrusted sources without proper sandboxing. DuckDB executes SQL with the full privileges of the user running it, much like a shell or scripting interpreter (such as bash or Python). Just as you wouldn't run an untrusted sh...all used functions to ensure you understand whether a function is safe to use with untrusted input under your specific use case. Extensions DuckDB has a flexible extension mechanism that adds functionality such as new file formats, functions, and rem... - https://man.mtool.work/duckdb/2.0/operations_manual/securing_duckdb/overview.htm...
- Importing Data 13467
- The first step to using a database system is to insert data into that system. DuckDB can directly connect to many popular data sources and offers several data ingestion methods that allow you to easily and efficiently fill up the database.
...On this page, we provide an overview of these methods so you can select which one is best suited for your use case. INSERT Statements INSERT statements are the standard way of loading data into a database system. They are suitable f...e VALUES (1, 'Mark'); For a more detailed description, see the page on the INSERT statement . File Loading: Relative Paths Use the configuration option file_search_path to configure to which “root directories” relative paths are expanded on. If file... - https://man.mtool.work/duckdb/2.0/data/overview.html
- Configuration 13027
- 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
...= 'memory_limit'; Examples Set the memory limit of the system to 10 GB. SET memory_limit = '10GB'; Configure the system to use 1 thread. SET threads TO 1; Turn logging on and set the logging level to debug . For additional details on logging levels,...OM duckdb_settings() WHERE name = 'threads'; name value description input_type scope threads 1 The number of total threads used by the system. BIGINT GLOBAL Show a list of all available settings: SELECT * FROM duckdb_settings(); Reset the memory lim...t_files (deprecated) Parquet files are now always prefetched, this setting has no effect BOOLEAN false preserve_identifier_case How to fold non-quoted identifiers. 'preserve_case' keeps the case as written, 'lowercase' lowercases them, 'uppercase' up... - https://man.mtool.work/duckdb/2.0/configuration/overview.html
- Legacy Authentication Scheme for S3 API 12850
- Prior to version 0.10.0, DuckDB did not have a Secrets manager . Hence, the configuration of and authentication to S3 endpoints was handled via variables. This page documents the legacy authentication scheme for the S3 API. Warning This pag
...re, avoid using these methods for storing secrets. The recommended way to configure and authenticate of S3 endpoints is to use secrets . Legacy Authentication Scheme To be able to read or write from S3, the correct region should be set: SET s3_regio...n = 'us-east-1'; Optionally, the endpoint can be configured in case a non-AWS object storage server is used: SET s3_endpoint = '⟨domain⟩.⟨tld⟩:⟨port⟩'; If the endpoint is not SSL-enabled the...n run: SET s3_use_ssl = false; Switching between path-style and vhost-style URLs is possible using: SET s3_url_style = 'path'; However, note... - https://man.mtool.work/duckdb/2.0/core_extensions/httpfs/s3api_legacy_authentica...
- Python DB API 12550
- The standard DuckDB Python API provides a SQL interface compliant with the DB-API 2.0 specification described by PEP 249 similar to the SQLite Python API . Connection To use the module, you must first create a DuckDBPyConnection object that
...e duckdb.connect method, which takes three arguments: database , read_only and config . The config keyword argument can be used to provide a dict that contains key-value pairs referencing settings understood by DuckDB. In-Memory Connection The speci...al value :memory: can be used to create an in-memory database . Note that for an in-memory database no data is persisted to disk (i.e., all data is los...T item FROM items WHERE value > $minimum", {"minimum": 40}, ).fetchall() print(rows) [('hammer',)] Parameter names are not case sensitive: the key "ABC" binds $abc , so do not pass two keys that differ only in case. Insert a row with ? placeholders,... - https://man.mtool.work/duckdb/2.0/clients/python/dbapi.html
DuckDB 2.0 Documentation / man.mtool.work