⌘K ctrl+k
Search Shortcut cmd + k | ctrl + k
DuckDB 2.0 ドキュメント 全文検索
per page, with , order by , clip by
Results of 1 - 8 of about 8 for Alice (0.002 sec.)
Variant Type 12977
The VARIANT type stores typed, binary data where each row is self-contained with its own type information. This differs from the JSON type , which is physically stored as text. Because type metadata is embedded per-value, VARIANT provides b ... VARIANT); INSERT INTO events VALUES (1, 42::VARIANT), (2, 'hello world'::VARIANT), (3, [1, 2, 3]::VARIANT), (4, {'name': 'Alice', 'age': 30}::VARIANT); SELECT * FROM events; ┌───────┬────────────────────────────┐ │ id │ data │ │ int32 │ variant │ ├── ... ─────┼────────────────────────────┤ │ 1 │ 42 │ │ 2 │ hello world │ │ 3 │ [1, 2, 3] │ │ 4 │ {'age': 30, 'name': Alice} │ └───────┴────────────────────────────┘ Note that the keys of VARIANT objects are sorted: {'name': 'Alice', 'age': 30}:: ... VARIANT is returned as {'age': 30, 'name': Alice} . Checking the Type of a Value Use variant_typeof to inspect the underlying type of each row: SELECT id, data, variant_ty ...
https://man.mtool.work/duckdb/2.0/sql/data_types/variant.html
Graph Queries 11007
DuckDB supports graph queries via the DuckPGQ community extension , which implements the SQL/PGQ syntax from the SQL:2023 standard. Warning DuckPGQ is a community extension and is still under active development. It may not be available for ... GINT, name VARCHAR); CREATE TABLE Knows (person1_id BIGINT, person2_id BIGINT, since DATE); INSERT INTO Person VALUES (1, 'Alice'), (2, 'Bob'), (3, 'Charlie'); INSERT INTO Knows VALUES (1, 2, '2020-01-01'), (2, 3, '2021-06-15'); CREATE PROPERTY GRAPH ... rk MATCH (a:Person)-[k:Knows]->(b:Person) COLUMNS (a.name AS person1, b.name AS person2, k.since) ); person1 person2 since Alice Bob 2020-01-01 Bob Charlie 2021-06-15 Path Finding Find paths of variable length using quantifiers like {1,5} (1 to 5 hops ... ne or more): FROM GRAPH_TABLE (social_network MATCH p = ANY SHORTEST (a:Person)-[k:Knows]->{1,3}(b:Person) WHERE a.name = 'Alice' AND b.name = 'Charlie' COLUMNS (a.name AS start_person, b.name AS end_person, path_length(p) AS hops) ); start_person end ...
https://man.mtool.work/duckdb/2.0/guides/sql_features/graph_queries.html
COPY Statement 8567
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 ... gzip_explicit"} Sets all values of single rows to be returned as nested arrays to array_true.json : COPY (SELECT 1 AS id, 'Alice' AS name, [1, 2, 3] AS numbers UNION ALL SELECT 2, 'Bob', [4, 5, 6] AS numbers) TO 'array_true.json' (FORMAT json, ARRAY t ... rue); -- RETURNS: /* [ {"id":1,"name":"Alice","numbers":[1,2,3]}, {"id":2,"name":"Bob","numbers":[4,5,6]} ] */ Sets all values of single rows to be returned as non-nes ... ted arrays to array_false.json : COPY (SELECT 1 AS id, 'Alice' AS name, [1, 2, 3] AS numbers UNION ALL SELECT 2, 'Bob', [4, 5, 6] AS numbers) TO 'array_false.json' (FORMAT json, ARRAY ...
https://man.mtool.work/duckdb/2.0/sql/statements/copy.html
Create Synthetic Data 8440
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 ... erates rows from literal tuples, which is convenient for a small fixed set of values to draw from: SELECT * FROM (VALUES ('Alice', 'Engineering'), ('Bob', 'Sales')) t(name, department); ┌─────────┬─────────────┐ │ name │ department │ │ varchar │ varch ... ar │ ├─────────┼─────────────┤ │ Alice │ Engineering │ │ Bob │ Sales │ └─────────┴─────────────┘ repeat_row repeat_row(varargs, num_rows) returns a fixed number ...
https://man.mtool.work/duckdb/2.0/guides/snippets/create_synthetic_data.html
Security 8097
This page covers Quack's security posture end to end: what the server exposes, what stays local, the role of a TLS-terminating reverse proxy, and the authentication / authorization callbacks the server runs on every connection and every que ... (e.g., one per user): CREATE TABLE quack_tokens (auth_token VARCHAR, user_name VARCHAR); INSERT INTO quack_tokens VALUES ('alice-key-123', 'alice'), ('bob-key-456', 'bob'); CREATE MACRO check_token(sid, client_token, server_token) AS ( EXISTS (SELECT ...
https://man.mtool.work/duckdb/2.0/quack/security.html
Prepared Statements 7862
DuckDB supports prepared statements where parameters are substituted when the query is executed. This can improve readability and is useful for preventing SQL injections . Syntax There are three syntaxes for denoting parameters in prepared ... them with examples using the following table. CREATE TABLE person (name VARCHAR, age BIGINT); INSERT INTO person VALUES ('Alice', 37), ('Ana', 35), ('Bob', 41), ('Bea', 25); In our example query, we'll look for people whose name starts with a B and a ...
https://man.mtool.work/duckdb/2.0/sql/query_syntax/prepared_statements.html
Run Queries 7627
Overview Because the Go client implements database/sql , queries run through the standard methods: Exec and ExecContext send statements that do not return rows, such as INSERT or DDL, and report the number of affected rows. Query , QueryCon ... holders such as $name , wrap each argument with sql.Named : row := db.QueryRowContext(ctx, "SELECT $age >= 18 AND $name = 'Alice'", sql.Named("age", minAge), sql.Named("name", name), ) Warning Do not use prepared statements to insert large amounts of ...
https://man.mtool.work/duckdb/2.0/clients/go/querying.html
Run Queries 7627
Overview A Connection runs SQL through two families of methods: The execute_* methods ( execute() and execute_batch() ) send statements that do not return rows, such as INSERT or DDL, and report the number of affected rows. The query_* meth ... ers such as $name , use the named_params! macro: use duckdb::named_params; conn.query_row( "SELECT $age >= 18 AND $name = 'Alice'", named_params! { "age": min_age, "name": name, }, |row| row.get(0), )?; Any value bound as a parameter implements the To ...
https://man.mtool.work/duckdb/2.0/clients/rust/querying.html
PREV 1 NEXT
DuckDB 2.0 Documentation / man.mtool.work