⌘K ctrl+k
Search Shortcut cmd + k | ctrl + k
DuckDB 2.0 ドキュメント 全文検索
per page, with , order by , clip by
Results of 1 - 7 of about 7 for param (0.014 sec.)
Complete API 12323
This page contains the reference for DuckDB's C API. The reference contains several deprecation notices. These concern methods whose long-term availability is not guaranteed as they may be removed in the future. That said, DuckDB's develope ... * prepared_statement ); const char * duckdb_prepare_error ( duckdb_prepared_statement prepared_statement ); idx_t duckdb_nparams ( duckdb_prepared_statement prepared_statement ); const char * duckdb_parameter_name ( duckdb_prepared_statement prepared ... _statement , idx_t index ); duckdb_type duckdb_param_type ( duckdb_prepared_statement prepared_statement , idx_t param_idx ); duckdb_logical_type duckdb_param_logical_type ( d ... uckdb_prepared_statement prepared_statement , idx_t param_idx ); duckdb_state duckdb_clear_bindings ( duckdb_prepared_statement prepared_statement ); duckdb_statement_type duckdb_p ...
https://man.mtool.work/duckdb/2.0/clients/c/api.html
Prepared Statements 11541
A prepared statement is a parameterized query. The query is prepared with question marks ( ? ) or dollar symbols ( $1 ) indicating the parameters of the query. Values can then be bound to these parameters, after which the prepared statement ... can be executed using those parameters. A single query can be prepared once and executed many times. Prepared statements are useful to: Easily supply parame ... e avoiding string concatenation/SQL injection attacks. Speeding up queries that will be executed many times with different parameters. DuckDB supports prepared statements in the C API with the duckdb_prepare method. The duckdb_bind family of functions ... "INSERT INTO integers VALUES ($1, $2)", &stmt) == DuckDBError) { // handle error } duckdb_bind_int32(stmt, 1, 42); // the parameter index starts counting at 1! duckdb_bind_int32(stmt, 2, 43); // NULL as second parameter means no result set is request ...
https://man.mtool.work/duckdb/2.0/clients/c/prepared.html
Lambda Functions 8088
DuckDB lambda functions (a.k.a. 'lambdas' or 'lambda expressions') are expressions that define an inline anonymous function. Lambdas are passed as argument to certain list functions , which evaluate the passed lambda expression against its ... ilter: if it evaluates to true , the column is retained, and discarded otherwise. COLUMNS -clause lambdas have a mandatory parameter that receives the column name. Optionally, a second parameter may be declared that receives the (1-based) column index ... . The syntax for a lambda expression is: lambda ⟨parameters⟩ : ⟨expression⟩ ⟨parameters⟩ is a comma-separated list of parameter names. Parameters may be given any name, and thei ... r name may be referenced in the ⟨expression⟩ . The number of allowed and required parameters depends on the list function to which it is passed. There is always a mandatory parameter that is used by the list fu ...
https://man.mtool.work/duckdb/2.0/sql/functions/lambda.html
Write User Defined Functions 7979
Overview The JDBC driver can register user-defined functions (UDFs) written in Java, including scalar functions and table functions. This page covers building and registering both, from the simple functional-interface overloads to the vecto ... tion conn = DriverManager.getConnection("jdbc:duckdb:")) { DuckDBFunctions.scalarFunction() .withName("java_add_one") .withParameter(int.class) .withReturnType(int.class) .withIntFunction(x -> x + 1) .register(conn); } SELECT java_add_one(41); The bin ... ary overloads take two arguments of the same type, declared with withParameters() : DuckDBFunctions.scalarFunction() .withName("java_weighted_sum") .withParameters(double.class, double.class) .with ... pe = DuckDBLogicalType.of(DuckDBColumnType.INTEGER)) { DuckDBFunctions.scalarFunction() .withName("java_sum_varargs") .withParameter(Integer.class) // fixed argument .withVarArgs(intType) // variadic argument type .withReturnType(Integer.class) .withV ...
https://man.mtool.work/duckdb/2.0/clients/java/functions.html
Prepared Statements 7979
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 ... statements: auto-incremented ( ? ), positional ( $1 ), and named ( $param ). Note that not all clients support all of these syntaxes, e.g., the JDBC client only supports auto-incremented parameter ... ple whose name starts with a B and are at least 40 years old. This will return a single row <'Bob', 41> . Auto-Incremented Parameters: ? DuckDB supports using prepared statements with auto-incremented indexing, i.e., the position of the parameters in ... me, ?) AND age >= ?; Using the CLI client, the statement is executed as follows. EXECUTE query_person('B', 40); Positional Parameters: $1 Prepared statements can use positional parameters, where parameters are denoted with an integer ( $1 , $2 ). For ...
https://man.mtool.work/duckdb/2.0/sql/query_syntax/prepared_statements.html
SQL to/from JSON 7852
DuckDB provides functions to serialize and deserialize SELECT statements between SQL and JSON, as well as executing JSON serialized statements. Function Type Description json_deserialize_sql(json) Scalar Deserialize one or many json seriali ... Pragma version of the json_execute_serialized_sql function. The json_serialize_sql(varchar) function takes three optional parameters, skip_empty , skip_null and format that can be used to control the output of the serialized statements. If you run th ... xpressions":[],"group_sets":[],"aggregate_handling":"STANDARD_HANDLING","having":null,"sample":null,"qualify":null},"named_param_map":[]}]} Example with multiple statements and skip options: SELECT json_serialize_sql('SELECT 1 + 2; SELECT a + b FROM t ...
https://man.mtool.work/duckdb/2.0/data/json/sql_to_and_from_json.html
Logging 7797
DuckDB implements a logging mechanism that provides users with detailed information about events such as query execution, performance metrics and system events. Warning Logs may contain sensitive information, including secrets and credentia ... rt_time, duration_ms, headers MAP) , response STRUCT(status, reason, headers MAP) PhysicalOperator operator_type VARCHAR , parameters MAP(VARCHAR, VARCHAR) , class VARCHAR , event VARCHAR , info MAP(VARCHAR, VARCHAR) Metrics metric VARCHAR , value VAR ... ging(storage = 'file', storage_config = {'path': 'path/to/store/logs'}); -- using shorthand for common path storage config param CALL enable_logging(storage = 'file', storage_path = 'path/to/store/logs'); -- omitting `storage = 'file'` -> is implied f ...
https://man.mtool.work/duckdb/2.0/operations_manual/logging/overview.html
PREV 1 NEXT
DuckDB 2.0 Documentation / man.mtool.work