Skip to content
Blog

Connection configuration

The configuration of a connection to Kùzu database can be changed through a standalone CALL statement, described in this section. Different from the CALL clause, this statement of changing configuration cannot be used with other query clauses.

OptionDescription
THREADSnumber of threads used by execution
TIMEOUTtimeout of query execution in ms
VAR_LENGTH_EXTEND_MAX_DEPTHmaximum depth of var length extend
ENABLE_SEMI_MASKenables the semi mask optimization

Change number of threads for execution

CALL THREADS=5;
CALL current_setting('threads') return *;
-----------
| threads |
-----------
| 5 |
-----------

Change query timeout

CALL TIMEOUT=3000;
CALL current_setting('timeout') return *;
-----------
| timeout |
-----------
| 3000 |
-----------

Change maximum depth of var_length_extend

CALL var_length_extend_max_depth=10;
CALL current_setting('var_length_extend_max_depth') RETURN *;
-------------------------------
| var_length_extend_max_depth |
-------------------------------
| 10 |
-------------------------------

Disable semi-mask optimization

CALL enable_semi_mask=false;
CALL current_setting('enable_semi_mask') RETURN *;
--------------------
| enable_semi_mask |
--------------------
| false |
--------------------