Results of 1 - 10 of about 31 for else (0.006 sec.)
- Relational API – DuckDB 15303
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...() rel = duckdb_conn . sql ( """ select gen_random_uuid() as id, concat('value is ', case when mod(range,2)=0 then 'even' else 'uneven' end) as description, range as value, now() + concat(range,' ', 'minutes')::interval as created_timestamp from ran...() rel = duckdb_conn . sql ( """ select gen_random_uuid() as id, concat('value is ', case when mod(range,2)=0 then 'even' else 'uneven' end) as description, range as value, now() + concat(range,' ', 'minutes')::interval as created_timestamp from ran...() rel = duckdb_conn . sql ( """ select gen_random_uuid() as id, concat('value is ', case when mod(range,2)=0 then 'even' else 'uneven' end) as description, range as value, now() + concat(range,' ', 'minutes')::interval as created_timestamp from ran... - https://man.mtool.work/duckdb/1.3/clients/python/relational_api.html
- Map Functions – DuckDB 10709
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...y is not contained in the map. The type of the key provided in the second parameter must match the type of the map's keys; else, an error is thrown. map_concat(maps...) Returns a map created from merging the input maps . On key collision the value is...y is not contained in the map. The type of the key provided in the second parameter must match the type of the map's keys; else, an error is thrown. map_extract_value(map, key) Returns the value for a given key or NULL if the key is not contained in...the map. The type of the key provided in the second parameter must match the type of the map's keys; else, an error is thrown. map_from_entries(STRUCT(k, v)[]) Returns a map created from the entries of the array. map_keys(map) R... - https://man.mtool.work/duckdb/1.3/sql/functions/map.html
- Vectors – DuckDB 9900
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...ullptr , & db ); duckdb_connect ( db , & con ); duckdb_result res ; duckdb_query ( con , "SELECT CASE WHEN i%2=0 THEN NULL ELSE i END res_col FROM range(10) t(i)" , & res ); // iterate until result is exhausted while ( true ) { duckdb_data_chunk resu...; row ++ ) { if ( duckdb_validity_row_is_valid ( vector_validity , row )) { printf ( "%lld \n " , vector_data [ row ]); } else { printf ( "NULL \n " ); } } duckdb_destroy_data_chunk ( & result ); } // clean-up duckdb_destroy_result ( & res ); duckdb...; duckdb_connect ( db , & con ); duckdb_result res ; duckdb_query ( con , "SELECT CASE WHEN i%2=0 THEN CONCAT('short_', i) ELSE CONCAT('longstringprefix', i) END FROM range(10) t(i)" , & res ); // iterate until result is exhausted while ( true ) { du... - https://man.mtool.work/duckdb/1.3/clients/c/vector.html
- CASE Expression – DuckDB 9496
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...condition. The basic form is identical to the ternary condition used in many programming languages ( CASE WHEN cond THEN a ELSE b END is equivalent to cond ? a : b ). With a single condition this can be expressed with IF(cond, a, b) . CREATE OR REPLA...CE TABLE integers AS SELECT unnest ([ 1 , 2 , 3 ]) AS i ; SELECT i , CASE WHEN i > 2 THEN 1 ELSE 0 END AS test FROM integers ; i test 1 0 2 0 3 1 This is equivalent to: SELECT i , IF ( i > 2 , 1 , 0 ) AS test FROM integ...TE OR REPLACE TABLE integers AS SELECT unnest ([ 1 , 2 , 3 ]) AS i ; SELECT i , CASE WHEN i = 1 THEN 10 WHEN i = 2 THEN 20 ELSE 0 END AS test FROM integers ; i test 1 10 2 20 3 0 The ELSE clause of the CASE expression is optional. If no ELSE clause i... - https://man.mtool.work/duckdb/1.3/sql/expressions/case.html
- Utility Functions – DuckDB 9318
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...eturn NULL . Otherwise, return arg1 . count_if(x) Aggregate function; rows contribute 1 if x is true or a non-zero number, else 0. create_sort_key(parameters...) Constructs a binary-comparable sort key based on a set of input parameters and sort qual...ng as a UBIGINT . nextval('sequence_name') Return the following value of the sequence. nullif(a, b) Return NULL if a = b , else return a . Equivalent to CASE WHEN a = b THEN NULL ELSE a END . pg_typeof(expression) Returns the lower case name of the d...ull(42, NULL) Result NULL count_if(x) Description Aggregate function; rows contribute 1 if x is true or a non-zero number, else 0. Example count_if(42) Result 1 create_sort_key(parameters...) Description Constructs a binary-comparable sort key based... - https://man.mtool.work/duckdb/1.3/sql/functions/utility.html
- Expression API – DuckDB 8832
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...│ hello │ │ hello │ │ hello │ │ hello │ └─────────┘ Case Expression This expression contains a CASE WHEN (...) THEN (...) ELSE (...) END expression. By default ELSE is NULL and it can be set using .else(value = ...) . Additional WHEN (...) THEN (......ct ( case ). show () ┌──────────────────────────────────────────────────────────┐ │ CASE WHEN ((b = false)) THEN ('world') ELSE 'hello' END │ │ varchar │ ├──────────────────────────────────────────────────────────┤ │ hello │ │ hello │ │ world │ │ hel...( "b is true" ) ). select ( SQLExpression ( "a" ). alias ( "selecting_column_a" ), SQLExpression ( "case when a = 1 then 1 else 0 end" ). alias ( "selecting_case_expression" ), SQLExpression ( "1" ). alias ( "constant_numeric_column" ), SQLExpression... - https://man.mtool.work/duckdb/1.3/clients/python/expression.html
- Node.js API – DuckDB 8590
- This page is for DuckDB 1.3, which is outdated. Switch to the current documentation . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Ove
...ll for example all() on the stmt object: stmt . all ( 42 , function ( err , res ) { if ( err ) { console . warn ( err ); } else { console . log ( res [ 0 ]. fortytwo ) } }); You can also execute the prepared statement multiple times. This is for exam...); } stmt . finalize (); con . all ( ' SELECT * FROM a ' , function ( err , res ) { if ( err ) { console . warn ( err ); } else { console . log ( res ) } }); prepare() can also take a callback which gets the prepared statement as an argument: const s...S fortytwo ' , function ( err , stmt ) { stmt . all ( 42 , function ( err , res ) { if ( err ) { console . warn ( err ); } else { console . log ( res [ 0 ]. fortytwo ) } }); }); Inserting Data via Arrow Apache Arrow can be used to insert data into Du... - https://man.mtool.work/duckdb/1.3/clients/nodejs/overview.html
- Timestamp with Time Zone Functions – DuckDB 8509
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...h . The grid is anchored at 2000-01-01 00:00:00+00:00[ + offset] when bucket_width is a number of months or coarser units, else 2000-01-03 00:00:00+00:00[ + offset] . Note that 2000-01-03 is a Monday. time_bucket(bucket_width, timestamptz[, origin])...he origin timestamp, which defaults to 2000-01-01 00:00:00+00:00 when bucket_width is a number of months or coarser units, else 2000-01-03 00:00:00+00:00 . Note that 2000-01-03 is a Monday. time_bucket(bucket_width, timestamptz[, timezone]) Truncate..., which defaults to 2000-01-01 00:00:00 in the provided timezone when bucket_width is a number of months or coarser units, else 2000-01-03 00:00:00 in the provided timezone . The default timezone is 'UTC' . Note that 2000-01-03 is a Monday. age(times... - https://man.mtool.work/duckdb/1.3/sql/functions/timestamptz.html
- Date Functions – DuckDB 8266
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...dth bucket_width . The grid is anchored at 2000-01-01[ + offset] when bucket_width is a number of months or coarser units, else 2000-01-03[ + offset] . Note that 2000-01-03 is a Monday. time_bucket(bucket_width, date[, origin]) Truncate timestamptz t...s anchored at the origin timestamp, which defaults to 2000-01-01 when bucket_width is a number of months or coarser units, else 2000-01-03 . Note that 2000-01-03 is a Monday. today() Current date (start of current transaction) in UTC. current_date De...dth bucket_width . The grid is anchored at 2000-01-01[ + offset] when bucket_width is a number of months or coarser units, else 2000-01-03[ + offset] . Note that 2000-01-03 is a Monday. Example time_bucket(INTERVAL '2 months', DATE '1992-04-20', INTE... - https://man.mtool.work/duckdb/1.3/sql/functions/date.html
- Information Schema – DuckDB 8185
- This page is for DuckDB 1.3, which is outdated. Switch to the current version . Search Shortcut cmd + k | ctrl + k Installation Documentation Getting Started Connect Overview Concurrency Data Import Overview Data Sources CSV Files Overview
...of the database encoding. VARCHAR 'UTF8' character_repertoire Character repertoire, showing UCS if the encoding is UTF8 , else just the encoding name. VARCHAR 'UCS' form_of_use Character encoding form, same as the database encoding. VARCHAR 'UTF8' d...the table is a typed table, the name of the database that contains the underlying data type (always the current database), else NULL . Currently unimplemented. VARCHAR NULL user_defined_type_schema If the table is a typed table, the name of the schem...a that contains the underlying data type, else NULL . Currently unimplemented. VARCHAR NULL user_defined_type_name If the table is a typed table, the name of the underly... - https://man.mtool.work/duckdb/1.3/sql/meta/information_schema.html
DuckDB 1.3 Documentation / man.mtool.work