⌘K ctrl+k
Search Shortcut cmd + k | ctrl + k
DuckDB 2.0 ドキュメント 全文検索
per page, with , order by , clip by
Results of 1 - 10 of about 33 for turn (0.002 sec.)
Dot Commands 13444
Dot commands are available in the DuckDB CLI client. To use one of these commands, begin the line with a period ( . ) immediately followed by the name of the command you wish to execute. Additional arguments to the command are entered, spac ... ically format SQL before execution. Default: off .bail ⟨on/off⟩ Stop after hitting an error. Default: off .binary ⟨on/off⟩ Turn binary output on or off . Default: off .cd ⟨DIRECTORY⟩ Change the working directory to DIRECTORY .changes ⟨on/off⟩ Show nu ... .display_colors ⟨bold/underline⟩ Display all terminal colors and their names. See the 8-bit colors section .echo ⟨on/off⟩ Turn command echo on or off .edit Open an external text editor to edit a query. \e can be used as an alias. See the external ed ... xcel Display the output of the next command in a spreadsheet. Equivalent to .once -x .exit ⟨CODE⟩ Exit this program with return-code CODE .headers ⟨on/off⟩ Turn display of headers on or off . Does not apply to duckbox mode .help ⟨-all⟩ ⟨PATTERN⟩ Show ...
https://man.mtool.work/duckdb/2.0/clients/cli/dot_commands.html
Join Operations 13444
How to Force a Join Order DuckDB has a cost-based query optimizer, which uses statistics in the base tables (stored in a DuckDB database or Parquet files) to estimate the cardinality of operations. Turn off the Join Order Optimizer To turn ... . -- this join is performed first JOIN ...; -- this join is performed second Once the query in question has been executed, turn back the optimizers with the following command: SET disabled_optimizers = ''; Create Temporary Tables To force a particula ...
https://man.mtool.work/duckdb/2.0/guides/performance/join_operations.html
Command Line Arguments 9465
The table below summarizes DuckDB's command line options. To list all command line options, use the command: duckdb -help For a list of dot commands available in the CLI shell, see the Dot Commands page . Argument Description -agent Render ... ME , writing the result to stdout -init FILENAME Run the script in FILENAME upon startup (instead of ~/.duckdbrc ) -header Turn headers on -h Show the help message -help Show the help message -html Set output mode to HTML -interactive Force interacti ... gent. See the Agent Mode page -no-init Skip processing the init file ( ~/.duckdbrc or the file passed to -init ) -noheader Turn headers off -no-stdin Exit after processing options instead of reading stdin -nullvalue TEXT Set text string for NULL valu ... ilarly to the behavior of the SQLite CLI. For example: duckdb -csv -c 'SELECT 42 AS hello' -json -c 'SELECT 84 AS world' Returns the following: hello 42 [{"world":84}] The -init script (or the default ~/.duckdbrc when -init is not given) is an except ...
https://man.mtool.work/duckdb/2.0/clients/cli/arguments.html
Command Line 9465
Unexpected Markdown Output When Piping If the output of the command line client is piped to another process and an AI agent environment variable (such as AI_AGENT ) is set, the CLI switches to agent mode and prints compact Markdown tables i ... nstead of the usual duckbox tables: echo "SELECT 42 AS x;" | duckdb | cat | x:INTEGER | |---| | 42 | To turn off agent mode, use the -no-agent command line argument or set the DUCKDB_AGENT_MODE environment variable to 0 : echo "SEL ...
https://man.mtool.work/duckdb/2.0/guides/troubleshooting/command_line.html
Profiling 9240
Profiling is essential to help understand why certain queries exhibit specific performance characteristics. DuckDB contains several built-in features to enable query profiling, which this page covers. For a high-level example of using EXPLA ... command does the same for the previous query. Both are disabled in safe mode . Pragmas DuckDB supports several pragmas for turning profiling on and off and controlling the level of detail in the profiling output. The following pragmas are available a ... on, see the “Profiling” section of the pragmas page. Setting Description Default Options enable_profiling , enable_profile Turn on profiling query_tree query_tree , json , query_tree_optimizer , no_output profiling_coverage Set the operators to profi ... ric glob patterns, e.g. ['query.*', 'optimizer.*'] . ( List of all available metrics ) disable_profiling , disable_profile Turn off profiling Table Functions These table functions were introduced in DuckDB 1.5.0. DuckDB provides table functions to en ...
https://man.mtool.work/duckdb/2.0/dev/profiling.html
Create Synthetic Data 9000
DuckDB lets you quickly generate synthetic datasets by combining a few building blocks: functions and clauses that generate rows , functions that generate values to fill those rows, and extensions that generate whole benchmark datasets. Thi ... ackage via the Python function API using cross products (Cartesian products) range and generate_series The range functions turn a start, stop, and step into a table of rows, which is the usual starting point for a synthetic dataset: SELECT i FROM ran ... ────────────┤ │ Alice │ Engineering │ │ Bob │ Sales │ └─────────┴─────────────┘ repeat_row repeat_row(varargs, num_rows) returns a fixed number of identical rows, which is useful as a scaffold to fill with generated values: FROM repeat_row('placehold ... number of rows: SELECT i, j FROM range(1, 3) s(i) CROSS JOIN range(1, 3) t(j); Generating Values Random Numbers random() returns a random DOUBLE in the range [0, 1) , which you can scale and cast into any numeric range: SELECT (random() * 100)::INTEG ...
https://man.mtool.work/duckdb/2.0/guides/snippets/create_synthetic_data.html
Keywords and Identifiers 9000
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 ... dentifiers are folded. It accepts the following values: 'preserve_case' (default): keep the case as written. 'lowercase' : turn non-quoted identifiers into lowercase. 'uppercase' : turn non-quoted identifiers into uppercase. For backward compatibilit ... 'lowercase' , respectively. For example, with preserve_identifier_case set to 'lowercase' , all non-quoted identifiers are turned into lowercase: SET preserve_identifier_case = 'lowercase'; CREATE TABLE tbl AS SELECT cos(pi()) AS CosineOfPi; SELECT C ... osineOfPi FROM tbl; cosineofpi -1.0 With preserve_identifier_case set to 'uppercase' , they are turned into uppercase, so the table above would be named TBL and its column COSINEOFPI . The setting is applied when a statemen ...
https://man.mtool.work/duckdb/2.0/sql/dialect/keywords_and_identifiers.html
Friendly SQL 8775
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 ... g tables and computing statistics: DESCRIBE : provides a succinct summary of the schema of a table or query. SUMMARIZE : returns summary statistics for a table or query. Making SQL clauses more compact and readable: FROM -first syntax with an optiona ... of 42 AS x for improved readability. Specifying a percentage of the table size for the LIMIT clause : write LIMIT 10% to return 10% of the query results. FETCH FIRST : the SQL-standard alternative to LIMIT , e.g., FETCH FIRST 5 ROWS ONLY . Grouping b ... y UNNEST : use unnest() directly in the GROUP BY clause to group by the elements of a list. Transforming tables: PIVOT to turn long tables to wide tables. UNPIVOT to turn wide tables to long tables. Defining SQL-level variables: SET VARIABLE RESET V ...
https://man.mtool.work/duckdb/2.0/sql/dialect/friendly_sql.html
CHECKPOINT Statement 8534
The CHECKPOINT statement synchronizes data in the write-ahead log (WAL) to the database data file. Examples Synchronize data in the default database: CHECKPOINT; Synchronize data in the specified database: CHECKPOINT file_db; Synchronize da ... checkpointing. This has two key benefits: In-memory tables also support compression. This is disabled by default – you can turn it on using: sql ATTACH ':memory:' AS memory_compressed (COMPRESS); USE memory_compressed; Checkpointing triggers vacuumin ...
https://man.mtool.work/duckdb/2.0/sql/statements/checkpoint.html
Profile and Monitor 7829
Overview The Go client can observe query execution: it can retrieve per-operator profiling metrics after a query runs, and register a log storage that receives DuckDB's log messages. Both are described below. Profiling Profiling information ... e() // Retrieve the metrics collected for that query. info, err := duckdb.GetProfilingInfo(conn) check(err) // Optionally, turn profiling off again. _, err = conn.ExecContext(context.Background(), `PRAGMA disable_profiling`) check(err) GetProfilingIn ... fo() returns a duckdb.ProfilingInfo , a tree that mirrors DuckDB's query plan. Each node has a Metrics map of metric name to value and ...
https://man.mtool.work/duckdb/2.0/clients/go/profiling.html
PREV 1 2 3 4 NEXT
DuckDB 2.0 Documentation / man.mtool.work