duckdb 0.8.2-dev1862.0 → 0.8.2-dev2044.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/binding.gyp +9 -9
- package/package.json +1 -1
- package/src/duckdb/src/catalog/catalog.cpp +1 -1
- package/src/duckdb/src/catalog/catalog_entry/index_catalog_entry.cpp +17 -41
- package/src/duckdb/src/catalog/catalog_entry/macro_catalog_entry.cpp +2 -10
- package/src/duckdb/src/catalog/catalog_entry/schema_catalog_entry.cpp +4 -14
- package/src/duckdb/src/catalog/catalog_entry/sequence_catalog_entry.cpp +11 -28
- package/src/duckdb/src/catalog/catalog_entry/table_catalog_entry.cpp +11 -38
- package/src/duckdb/src/catalog/catalog_entry/view_catalog_entry.cpp +11 -27
- package/src/duckdb/src/catalog/catalog_entry.cpp +25 -1
- package/src/duckdb/src/common/enum_util.cpp +187 -0
- package/src/duckdb/src/common/extra_type_info.cpp +1 -2
- package/src/duckdb/src/common/serializer/binary_deserializer.cpp +3 -0
- package/src/duckdb/src/common/serializer/binary_serializer.cpp +4 -4
- package/src/duckdb/src/common/types/column/column_data_collection.cpp +43 -0
- package/src/duckdb/src/common/types/hugeint.cpp +40 -0
- package/src/duckdb/src/common/types/vector.cpp +1 -1
- package/src/duckdb/src/common/types.cpp +0 -12
- package/src/duckdb/src/core_functions/function_list.cpp +1 -0
- package/src/duckdb/src/core_functions/scalar/string/to_base.cpp +66 -0
- package/src/duckdb/src/execution/operator/aggregate/physical_hash_aggregate.cpp +14 -11
- package/src/duckdb/src/execution/operator/aggregate/physical_perfecthash_aggregate.cpp +6 -4
- package/src/duckdb/src/execution/operator/aggregate/physical_ungrouped_aggregate.cpp +14 -12
- package/src/duckdb/src/execution/operator/aggregate/physical_window.cpp +6 -4
- package/src/duckdb/src/execution/operator/helper/physical_batch_collector.cpp +8 -6
- package/src/duckdb/src/execution/operator/helper/physical_explain_analyze.cpp +2 -2
- package/src/duckdb/src/execution/operator/helper/physical_limit.cpp +5 -3
- package/src/duckdb/src/execution/operator/helper/physical_materialized_collector.cpp +7 -5
- package/src/duckdb/src/execution/operator/helper/physical_vacuum.cpp +7 -5
- package/src/duckdb/src/execution/operator/join/physical_asof_join.cpp +5 -4
- package/src/duckdb/src/execution/operator/join/physical_blockwise_nl_join.cpp +2 -2
- package/src/duckdb/src/execution/operator/join/physical_delim_join.cpp +13 -6
- package/src/duckdb/src/execution/operator/join/physical_hash_join.cpp +7 -5
- package/src/duckdb/src/execution/operator/join/physical_iejoin.cpp +7 -5
- package/src/duckdb/src/execution/operator/join/physical_nested_loop_join.cpp +7 -4
- package/src/duckdb/src/execution/operator/join/physical_piecewise_merge_join.cpp +8 -6
- package/src/duckdb/src/execution/operator/order/physical_order.cpp +7 -5
- package/src/duckdb/src/execution/operator/order/physical_top_n.cpp +7 -5
- package/src/duckdb/src/execution/operator/persistent/physical_batch_copy_to_file.cpp +8 -6
- package/src/duckdb/src/execution/operator/persistent/physical_batch_insert.cpp +8 -7
- package/src/duckdb/src/execution/operator/persistent/physical_copy_to_file.cpp +8 -6
- package/src/duckdb/src/execution/operator/persistent/physical_fixed_batch_copy.cpp +11 -9
- package/src/duckdb/src/execution/operator/persistent/physical_insert.cpp +10 -10
- package/src/duckdb/src/execution/operator/persistent/physical_update.cpp +4 -2
- package/src/duckdb/src/execution/operator/schema/physical_create_index.cpp +7 -6
- package/src/duckdb/src/execution/physical_operator.cpp +3 -2
- package/src/duckdb/src/execution/physical_plan/plan_comparison_join.cpp +1 -1
- package/src/duckdb/src/function/table/version/pragma_version.cpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/index_catalog_entry.hpp +1 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/macro_catalog_entry.hpp +1 -4
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/schema_catalog_entry.hpp +2 -5
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/sequence_catalog_entry.hpp +1 -6
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/table_catalog_entry.hpp +2 -11
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/view_catalog_entry.hpp +2 -5
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry.hpp +14 -0
- package/src/duckdb/src/include/duckdb/common/bitpacking.hpp +70 -55
- package/src/duckdb/src/include/duckdb/common/constants.hpp +2 -0
- package/src/duckdb/src/include/duckdb/common/enum_util.hpp +40 -0
- package/src/duckdb/src/include/duckdb/common/enums/index_type.hpp +1 -1
- package/src/duckdb/src/include/duckdb/common/enums/operator_result_type.hpp +5 -1
- package/src/duckdb/src/include/duckdb/common/hugeint.hpp +15 -0
- package/src/duckdb/src/include/duckdb/common/index_vector.hpp +12 -0
- package/src/duckdb/src/include/duckdb/common/limits.hpp +52 -149
- package/src/duckdb/src/include/duckdb/common/numeric_utils.hpp +48 -0
- package/src/duckdb/src/include/duckdb/common/serializer/binary_deserializer.hpp +28 -4
- package/src/duckdb/src/include/duckdb/common/serializer/binary_serializer.hpp +12 -5
- package/src/duckdb/src/include/duckdb/common/serializer/deserialization_data.hpp +110 -0
- package/src/duckdb/src/include/duckdb/common/serializer/format_deserializer.hpp +46 -1
- package/src/duckdb/src/include/duckdb/common/serializer/format_serializer.hpp +23 -21
- package/src/duckdb/src/include/duckdb/common/serializer/serialization_traits.hpp +12 -4
- package/src/duckdb/src/include/duckdb/common/types/column/column_data_collection.hpp +3 -0
- package/src/duckdb/src/include/duckdb/core_functions/aggregate/distributive_functions.hpp +1 -1
- package/src/duckdb/src/include/duckdb/core_functions/scalar/operators_functions.hpp +1 -1
- package/src/duckdb/src/include/duckdb/core_functions/scalar/string_functions.hpp +9 -0
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_hash_aggregate.hpp +3 -3
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_perfecthash_aggregate.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_ungrouped_aggregate.hpp +3 -3
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_window.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_batch_collector.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_explain_analyze.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_limit.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_materialized_collector.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_vacuum.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_asof_join.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_blockwise_nl_join.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_delim_join.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_hash_join.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_iejoin.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_nested_loop_join.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_piecewise_merge_join.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/order/physical_order.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/order/physical_top_n.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_batch_copy_to_file.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_batch_insert.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_copy_to_file.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_fixed_batch_copy.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_insert.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_update.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_index.hpp +2 -2
- package/src/duckdb/src/include/duckdb/execution/physical_operator.hpp +3 -3
- package/src/duckdb/src/include/duckdb/execution/physical_operator_states.hpp +11 -0
- package/src/duckdb/src/include/duckdb/function/macro_function.hpp +3 -0
- package/src/duckdb/src/include/duckdb/function/scalar_macro_function.hpp +3 -0
- package/src/duckdb/src/include/duckdb/function/table_macro_function.hpp +3 -0
- package/src/duckdb/src/include/duckdb/main/extension_entries.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parallel/pipeline.hpp +0 -3
- package/src/duckdb/src/include/duckdb/parallel/pipeline_executor.hpp +3 -2
- package/src/duckdb/src/include/duckdb/parser/column_definition.hpp +6 -5
- package/src/duckdb/src/include/duckdb/parser/column_list.hpp +4 -0
- package/src/duckdb/src/include/duckdb/parser/constraint.hpp +5 -0
- package/src/duckdb/src/include/duckdb/parser/constraints/check_constraint.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/constraints/foreign_key_constraint.hpp +6 -0
- package/src/duckdb/src/include/duckdb/parser/constraints/not_null_constraint.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/constraints/unique_constraint.hpp +6 -0
- package/src/duckdb/src/include/duckdb/parser/expression/between_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/case_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/cast_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/collate_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/columnref_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/comparison_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/conjunction_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/constant_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/default_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/function_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/lambda_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/operator_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/parameter_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/positional_reference_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/star_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/subquery_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/expression/window_expression.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/parsed_data/alter_info.hpp +12 -1
- package/src/duckdb/src/include/duckdb/parser/parsed_data/alter_table_info.hpp +66 -2
- package/src/duckdb/src/include/duckdb/parser/parsed_data/attach_info.hpp +8 -1
- package/src/duckdb/src/include/duckdb/parser/parsed_data/copy_info.hpp +8 -1
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_index_info.hpp +4 -1
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_info.hpp +9 -2
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_macro_info.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_schema_info.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_sequence_info.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_table_info.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_type_info.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/create_view_info.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/detach_info.hpp +7 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/drop_info.hpp +7 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/exported_table_data.hpp +7 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/load_info.hpp +13 -3
- package/src/duckdb/src/include/duckdb/parser/parsed_data/parse_info.hpp +22 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/pragma_info.hpp +10 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/show_select_info.hpp +7 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/transaction_info.hpp +10 -0
- package/src/duckdb/src/include/duckdb/parser/parsed_data/vacuum_info.hpp +10 -0
- package/src/duckdb/src/include/duckdb/planner/bound_constraint.hpp +0 -8
- package/src/duckdb/src/include/duckdb/planner/bound_result_modifier.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/column_binding.hpp +5 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_between_expression.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_case_expression.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_cast_expression.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_columnref_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_comparison_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_conjunction_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_constant_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_default_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_lambda_expression.hpp +3 -1
- package/src/duckdb/src/include/duckdb/planner/expression/bound_lambdaref_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_operator_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_parameter_data.hpp +5 -2
- package/src/duckdb/src/include/duckdb/planner/expression/bound_parameter_expression.hpp +7 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_reference_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_unnest_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/list.hpp +1 -0
- package/src/duckdb/src/include/duckdb/planner/expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/joinside.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/logical_operator.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_aggregate.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_any_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_column_data_get.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_comparison_join.hpp +9 -2
- package/src/duckdb/src/include/duckdb/planner/operator/logical_create.hpp +9 -6
- package/src/duckdb/src/include/duckdb/planner/operator/logical_create_index.hpp +2 -16
- package/src/duckdb/src/include/duckdb/planner/operator/logical_create_table.hpp +10 -6
- package/src/duckdb/src/include/duckdb/planner/operator/logical_cross_product.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_cteref.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_delete.hpp +7 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_delim_get.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_distinct.hpp +6 -10
- package/src/duckdb/src/include/duckdb/planner/operator/logical_dummy_scan.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_empty_result.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_explain.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_expression_get.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_filter.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_insert.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_limit.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_limit_percent.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_materialized_cte.hpp +5 -2
- package/src/duckdb/src/include/duckdb/planner/operator/logical_order.hpp +7 -35
- package/src/duckdb/src/include/duckdb/planner/operator/logical_pivot.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_positional_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_projection.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_recursive_cte.hpp +5 -3
- package/src/duckdb/src/include/duckdb/planner/operator/logical_reset.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_sample.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_set.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_set_operation.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_show.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_simple.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_top_n.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_unnest.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_update.hpp +6 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_window.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_pivotref.hpp +3 -0
- package/src/duckdb/src/main/relation/join_relation.cpp +1 -1
- package/src/duckdb/src/optimizer/deliminator.cpp +5 -3
- package/src/duckdb/src/parallel/pipeline.cpp +0 -17
- package/src/duckdb/src/parallel/pipeline_executor.cpp +26 -7
- package/src/duckdb/src/parallel/pipeline_finish_event.cpp +55 -1
- package/src/duckdb/src/parser/column_definition.cpp +20 -32
- package/src/duckdb/src/parser/column_list.cpp +8 -0
- package/src/duckdb/src/parser/constraints/foreign_key_constraint.cpp +3 -0
- package/src/duckdb/src/parser/constraints/unique_constraint.cpp +3 -0
- package/src/duckdb/src/parser/expression/case_expression.cpp +0 -12
- package/src/duckdb/src/parser/parsed_data/alter_info.cpp +5 -2
- package/src/duckdb/src/parser/parsed_data/alter_table_info.cpp +38 -0
- package/src/duckdb/src/parser/parsed_data/create_index_info.cpp +3 -1
- package/src/duckdb/src/parser/parsed_data/create_sequence_info.cpp +2 -0
- package/src/duckdb/src/parser/parsed_data/detach_info.cpp +1 -1
- package/src/duckdb/src/parser/parsed_data/drop_info.cpp +1 -1
- package/src/duckdb/src/parser/parsed_data/sample_options.cpp +0 -18
- package/src/duckdb/src/parser/parsed_data/transaction_info.cpp +4 -1
- package/src/duckdb/src/parser/parsed_data/vacuum_info.cpp +1 -1
- package/src/duckdb/src/parser/query_node.cpp +0 -10
- package/src/duckdb/src/parser/result_modifier.cpp +0 -13
- package/src/duckdb/src/parser/statement/select_statement.cpp +0 -10
- package/src/duckdb/src/parser/tableref/pivotref.cpp +0 -16
- package/src/duckdb/src/parser/transform/statement/transform_create_index.cpp +5 -4
- package/src/duckdb/src/planner/binder/query_node/plan_subquery.cpp +1 -1
- package/src/duckdb/src/planner/binder/statement/bind_create.cpp +6 -1
- package/src/duckdb/src/planner/binder/tableref/bind_basetableref.cpp +13 -3
- package/src/duckdb/src/planner/expression/bound_between_expression.cpp +4 -0
- package/src/duckdb/src/planner/expression/bound_cast_expression.cpp +13 -6
- package/src/duckdb/src/planner/expression/bound_parameter_expression.cpp +20 -12
- package/src/duckdb/src/planner/logical_operator.cpp +13 -1
- package/src/duckdb/src/planner/operator/logical_comparison_join.cpp +16 -2
- package/src/duckdb/src/planner/operator/logical_create.cpp +14 -0
- package/src/duckdb/src/planner/operator/logical_create_index.cpp +20 -0
- package/src/duckdb/src/planner/operator/logical_create_table.cpp +16 -0
- package/src/duckdb/src/planner/operator/logical_delete.cpp +9 -2
- package/src/duckdb/src/planner/operator/logical_delim_join.cpp +2 -4
- package/src/duckdb/src/planner/operator/logical_distinct.cpp +13 -0
- package/src/duckdb/src/planner/operator/logical_explain.cpp +1 -1
- package/src/duckdb/src/planner/operator/logical_insert.cpp +8 -2
- package/src/duckdb/src/planner/operator/logical_materialized_cte.cpp +3 -2
- package/src/duckdb/src/planner/operator/logical_order.cpp +39 -0
- package/src/duckdb/src/planner/operator/logical_pivot.cpp +3 -0
- package/src/duckdb/src/planner/operator/logical_recursive_cte.cpp +5 -5
- package/src/duckdb/src/planner/operator/logical_sample.cpp +3 -0
- package/src/duckdb/src/planner/operator/logical_update.cpp +8 -2
- package/src/duckdb/src/planner/parsed_data/bound_create_table_info.cpp +4 -2
- package/src/duckdb/src/planner/planner.cpp +11 -0
- package/src/duckdb/src/storage/checkpoint_manager.cpp +23 -23
- package/src/duckdb/src/storage/compression/bitpacking.cpp +87 -63
- package/src/duckdb/src/storage/compression/bitpacking_hugeint.cpp +295 -0
- package/src/duckdb/src/storage/serialization/serialize_constraint.cpp +98 -0
- package/src/duckdb/src/storage/serialization/serialize_create_info.cpp +188 -0
- package/src/duckdb/src/storage/serialization/serialize_expression.cpp +274 -0
- package/src/duckdb/src/storage/serialization/serialize_logical_operator.cpp +729 -0
- package/src/duckdb/src/storage/serialization/serialize_macro_function.cpp +62 -0
- package/src/duckdb/src/storage/serialization/serialize_nodes.cpp +242 -0
- package/src/duckdb/src/storage/serialization/serialize_parse_info.cpp +419 -0
- package/src/duckdb/src/storage/serialization/serialize_parsed_expression.cpp +40 -38
- package/src/duckdb/src/storage/serialization/serialize_query_node.cpp +36 -36
- package/src/duckdb/src/storage/serialization/serialize_result_modifier.cpp +25 -14
- package/src/duckdb/src/storage/serialization/serialize_statement.cpp +22 -0
- package/src/duckdb/src/storage/serialization/serialize_tableref.cpp +47 -47
- package/src/duckdb/src/storage/serialization/serialize_types.cpp +25 -25
- package/src/duckdb/src/storage/storage_info.cpp +3 -2
- package/src/duckdb/src/storage/wal_replay.cpp +20 -19
- package/src/duckdb/ub_extension_icu_third_party_icu_i18n.cpp +6 -6
- package/src/duckdb/ub_src_core_functions_scalar_string.cpp +2 -0
- package/src/duckdb/ub_src_parser.cpp +0 -2
- package/src/duckdb/ub_src_storage_compression.cpp +2 -0
- package/src/duckdb/ub_src_storage_serialization.cpp +16 -0
- package/src/duckdb/src/parser/common_table_expression_info.cpp +0 -21
@@ -13,11 +13,17 @@
|
|
13
13
|
#include "duckdb/common/exception.hpp"
|
14
14
|
#include "duckdb/common/helper.hpp"
|
15
15
|
#include "duckdb/common/limits.hpp"
|
16
|
+
#include "duckdb/common/numeric_utils.hpp"
|
16
17
|
|
17
18
|
namespace duckdb {
|
18
19
|
|
19
20
|
using bitpacking_width_t = uint8_t;
|
20
21
|
|
22
|
+
struct HugeIntPacker {
|
23
|
+
static void Pack(const hugeint_t *__restrict in, uint32_t *__restrict out, bitpacking_width_t width);
|
24
|
+
static void Unpack(const uint32_t *__restrict in, hugeint_t *__restrict out, bitpacking_width_t width);
|
25
|
+
};
|
26
|
+
|
21
27
|
class BitpackingPrimitives {
|
22
28
|
|
23
29
|
public:
|
@@ -37,9 +43,7 @@ public:
|
|
37
43
|
idx_t misaligned_count = count % BITPACKING_ALGORITHM_GROUP_SIZE;
|
38
44
|
T tmp_buffer[BITPACKING_ALGORITHM_GROUP_SIZE]; // TODO maybe faster on the heap?
|
39
45
|
|
40
|
-
|
41
|
-
count -= misaligned_count;
|
42
|
-
}
|
46
|
+
count -= misaligned_count;
|
43
47
|
|
44
48
|
for (idx_t i = 0; i < count; i += BITPACKING_ALGORITHM_GROUP_SIZE) {
|
45
49
|
PackGroup<T>(dst + (i * width) / 8, src + i, width);
|
@@ -78,22 +82,22 @@ public:
|
|
78
82
|
}
|
79
83
|
|
80
84
|
// Calculates the minimum required number of bits per value that can store all values
|
81
|
-
template <class T>
|
85
|
+
template <class T, bool is_signed = NumericLimits<T>::IsSigned()>
|
82
86
|
inline static bitpacking_width_t MinimumBitWidth(T value) {
|
83
|
-
return FindMinimumBitWidth<T, BYTE_ALIGNED>(value, value);
|
87
|
+
return FindMinimumBitWidth<T, is_signed, BYTE_ALIGNED>(value, value);
|
84
88
|
}
|
85
89
|
|
86
90
|
// Calculates the minimum required number of bits per value that can store all values
|
87
|
-
template <class T>
|
91
|
+
template <class T, bool is_signed = NumericLimits<T>::IsSigned()>
|
88
92
|
inline static bitpacking_width_t MinimumBitWidth(T *values, idx_t count) {
|
89
|
-
return FindMinimumBitWidth<T, BYTE_ALIGNED>(values, count);
|
93
|
+
return FindMinimumBitWidth<T, is_signed, BYTE_ALIGNED>(values, count);
|
90
94
|
}
|
91
95
|
|
92
96
|
// Calculates the minimum required number of bits per value that can store all values,
|
93
97
|
// given a predetermined minimum and maximum value of the buffer
|
94
|
-
template <class T>
|
98
|
+
template <class T, bool is_signed = NumericLimits<T>::IsSigned()>
|
95
99
|
inline static bitpacking_width_t MinimumBitWidth(T minimum, T maximum) {
|
96
|
-
return FindMinimumBitWidth<T, BYTE_ALIGNED>(minimum, maximum);
|
100
|
+
return FindMinimumBitWidth<T, is_signed, BYTE_ALIGNED>(minimum, maximum);
|
97
101
|
}
|
98
102
|
|
99
103
|
inline static idx_t GetRequiredSize(idx_t count, bitpacking_width_t width) {
|
@@ -112,7 +116,7 @@ public:
|
|
112
116
|
}
|
113
117
|
|
114
118
|
private:
|
115
|
-
template <class T, bool round_to_next_byte = false>
|
119
|
+
template <class T, bool is_signed, bool round_to_next_byte = false>
|
116
120
|
static bitpacking_width_t FindMinimumBitWidth(T *values, idx_t count) {
|
117
121
|
T min_value = values[0];
|
118
122
|
T max_value = values[0];
|
@@ -122,7 +126,7 @@ private:
|
|
122
126
|
max_value = values[i];
|
123
127
|
}
|
124
128
|
|
125
|
-
if (
|
129
|
+
if (is_signed) {
|
126
130
|
if (values[i] < min_value) {
|
127
131
|
min_value = values[i];
|
128
132
|
}
|
@@ -132,12 +136,12 @@ private:
|
|
132
136
|
return FindMinimumBitWidth<T, round_to_next_byte>(min_value, max_value);
|
133
137
|
}
|
134
138
|
|
135
|
-
template <class T, bool round_to_next_byte = false>
|
139
|
+
template <class T, bool is_signed, bool round_to_next_byte = false>
|
136
140
|
static bitpacking_width_t FindMinimumBitWidth(T min_value, T max_value) {
|
137
141
|
bitpacking_width_t bitwidth;
|
138
142
|
T value;
|
139
143
|
|
140
|
-
if (
|
144
|
+
if (is_signed) {
|
141
145
|
if (min_value == NumericLimits<T>::Minimum()) {
|
142
146
|
// handle special case of the minimal value, as it cannot be negated like all other values.
|
143
147
|
return sizeof(T) * 8;
|
@@ -152,7 +156,7 @@ private:
|
|
152
156
|
return 0;
|
153
157
|
}
|
154
158
|
|
155
|
-
if (
|
159
|
+
if (is_signed) {
|
156
160
|
bitwidth = 1;
|
157
161
|
} else {
|
158
162
|
bitwidth = 0;
|
@@ -168,58 +172,37 @@ private:
|
|
168
172
|
// Assert results are correct
|
169
173
|
#ifdef DEBUG
|
170
174
|
if (bitwidth < sizeof(T) * 8 && bitwidth != 0) {
|
171
|
-
if (
|
172
|
-
D_ASSERT(
|
173
|
-
D_ASSERT(
|
175
|
+
if (is_signed) {
|
176
|
+
D_ASSERT(max_value <= (T(1) << (bitwidth - 1)) - 1);
|
177
|
+
D_ASSERT(min_value >= (T(-1) * ((T(1) << (bitwidth - 1)) - 1) - 1));
|
174
178
|
} else {
|
175
|
-
D_ASSERT(
|
179
|
+
D_ASSERT(max_value <= (T(1) << (bitwidth)) - 1);
|
176
180
|
}
|
177
181
|
}
|
178
182
|
#endif
|
179
183
|
if (round_to_next_byte) {
|
180
184
|
return (bitwidth / 8 + (bitwidth % 8 != 0)) * 8;
|
181
|
-
} else {
|
182
|
-
return bitwidth;
|
183
185
|
}
|
186
|
+
return bitwidth;
|
184
187
|
}
|
185
188
|
|
186
189
|
// Sign bit extension
|
187
|
-
template <class T, class T_U = typename
|
190
|
+
template <class T, class T_U = typename MakeUnsigned<T>::type>
|
188
191
|
static void SignExtend(data_ptr_t dst, bitpacking_width_t width) {
|
189
|
-
T const mask = (
|
192
|
+
T const mask = T_U(1) << (width - 1);
|
190
193
|
for (idx_t i = 0; i < BitpackingPrimitives::BITPACKING_ALGORITHM_GROUP_SIZE; ++i) {
|
191
194
|
T value = Load<T>(dst + i * sizeof(T));
|
192
|
-
value = value & (((
|
195
|
+
value = value & ((T_U(1) << width) - T_U(1));
|
193
196
|
T result = (value ^ mask) - mask;
|
194
197
|
Store(result, dst + i * sizeof(T));
|
195
198
|
}
|
196
199
|
}
|
197
200
|
|
198
|
-
template <class T>
|
199
|
-
static void UnPackGroup(data_ptr_t dst, data_ptr_t src, bitpacking_width_t width,
|
200
|
-
bool skip_sign_extension = false) {
|
201
|
-
if (std::is_same<T, uint8_t>::value || std::is_same<T, int8_t>::value) {
|
202
|
-
duckdb_fastpforlib::fastunpack((const uint8_t *)src, (uint8_t *)dst, (uint32_t)width);
|
203
|
-
} else if (std::is_same<T, uint16_t>::value || std::is_same<T, int16_t>::value) {
|
204
|
-
duckdb_fastpforlib::fastunpack((const uint16_t *)src, (uint16_t *)dst, (uint32_t)width);
|
205
|
-
} else if (std::is_same<T, uint32_t>::value || std::is_same<T, int32_t>::value) {
|
206
|
-
duckdb_fastpforlib::fastunpack((const uint32_t *)src, (uint32_t *)dst, (uint32_t)width);
|
207
|
-
} else if (std::is_same<T, uint64_t>::value || std::is_same<T, int64_t>::value) {
|
208
|
-
duckdb_fastpforlib::fastunpack((const uint32_t *)src, (uint64_t *)dst, (uint32_t)width);
|
209
|
-
} else {
|
210
|
-
throw InternalException("Unsupported type found in bitpacking.");
|
211
|
-
}
|
212
|
-
|
213
|
-
if (NumericLimits<T>::IsSigned() && !skip_sign_extension && width > 0 && width < sizeof(T) * 8) {
|
214
|
-
SignExtend<T>(dst, width);
|
215
|
-
}
|
216
|
-
}
|
217
|
-
|
218
201
|
// Prevent compression at widths that are ineffective
|
219
202
|
template <class T>
|
220
203
|
static bitpacking_width_t GetEffectiveWidth(bitpacking_width_t width) {
|
221
|
-
|
222
|
-
|
204
|
+
bitpacking_width_t bits_of_type = sizeof(T) * 8;
|
205
|
+
bitpacking_width_t type_size = sizeof(T);
|
223
206
|
if (width + type_size > bits_of_type) {
|
224
207
|
return bits_of_type;
|
225
208
|
}
|
@@ -227,17 +210,49 @@ private:
|
|
227
210
|
}
|
228
211
|
|
229
212
|
template <class T>
|
230
|
-
static void PackGroup(data_ptr_t dst, T *values, bitpacking_width_t width) {
|
231
|
-
if (std::is_same<T,
|
232
|
-
duckdb_fastpforlib::fastpack(
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
} else if (std::is_same<T,
|
238
|
-
duckdb_fastpforlib::fastpack(
|
213
|
+
static inline void PackGroup(data_ptr_t dst, T *values, bitpacking_width_t width) {
|
214
|
+
if (std::is_same<T, int8_t>::value || std::is_same<T, uint8_t>::value) {
|
215
|
+
duckdb_fastpforlib::fastpack(reinterpret_cast<const uint8_t *>(values), reinterpret_cast<uint8_t *>(dst),
|
216
|
+
static_cast<uint32_t>(width));
|
217
|
+
} else if (std::is_same<T, int16_t>::value || std::is_same<T, uint16_t>::value) {
|
218
|
+
duckdb_fastpforlib::fastpack(reinterpret_cast<const uint16_t *>(values), reinterpret_cast<uint16_t *>(dst),
|
219
|
+
static_cast<uint32_t>(width));
|
220
|
+
} else if (std::is_same<T, int32_t>::value || std::is_same<T, uint32_t>::value) {
|
221
|
+
duckdb_fastpforlib::fastpack(reinterpret_cast<const uint32_t *>(values), reinterpret_cast<uint32_t *>(dst),
|
222
|
+
static_cast<uint32_t>(width));
|
223
|
+
} else if (std::is_same<T, int64_t>::value || std::is_same<T, uint64_t>::value) {
|
224
|
+
duckdb_fastpforlib::fastpack(reinterpret_cast<const uint64_t *>(values), reinterpret_cast<uint32_t *>(dst),
|
225
|
+
static_cast<uint32_t>(width));
|
226
|
+
} else if (std::is_same<T, hugeint_t>::value) {
|
227
|
+
HugeIntPacker::Pack(reinterpret_cast<const hugeint_t *>(values), reinterpret_cast<uint32_t *>(dst), width);
|
239
228
|
} else {
|
240
|
-
throw InternalException("Unsupported type
|
229
|
+
throw InternalException("Unsupported type for bitpacking");
|
230
|
+
}
|
231
|
+
}
|
232
|
+
|
233
|
+
template <class T>
|
234
|
+
static inline void UnPackGroup(data_ptr_t dst, data_ptr_t src, bitpacking_width_t width,
|
235
|
+
bool skip_sign_extension = false) {
|
236
|
+
if (std::is_same<T, int8_t>::value || std::is_same<T, uint8_t>::value) {
|
237
|
+
duckdb_fastpforlib::fastunpack(reinterpret_cast<const uint8_t *>(src), reinterpret_cast<uint8_t *>(dst),
|
238
|
+
static_cast<uint32_t>(width));
|
239
|
+
} else if (std::is_same<T, int16_t>::value || std::is_same<T, uint16_t>::value) {
|
240
|
+
duckdb_fastpforlib::fastunpack(reinterpret_cast<const uint16_t *>(src), reinterpret_cast<uint16_t *>(dst),
|
241
|
+
static_cast<uint32_t>(width));
|
242
|
+
} else if (std::is_same<T, int32_t>::value || std::is_same<T, uint32_t>::value) {
|
243
|
+
duckdb_fastpforlib::fastunpack(reinterpret_cast<const uint32_t *>(src), reinterpret_cast<uint32_t *>(dst),
|
244
|
+
static_cast<uint32_t>(width));
|
245
|
+
} else if (std::is_same<T, int64_t>::value || std::is_same<T, uint64_t>::value) {
|
246
|
+
duckdb_fastpforlib::fastunpack(reinterpret_cast<const uint32_t *>(src), reinterpret_cast<uint64_t *>(dst),
|
247
|
+
static_cast<uint32_t>(width));
|
248
|
+
} else if (std::is_same<T, hugeint_t>::value) {
|
249
|
+
HugeIntPacker::Unpack(reinterpret_cast<const uint32_t *>(src), reinterpret_cast<hugeint_t *>(dst), width);
|
250
|
+
} else {
|
251
|
+
throw InternalException("Unsupported type for bitpacking");
|
252
|
+
}
|
253
|
+
|
254
|
+
if (NumericLimits<T>::IsSigned() && !skip_sign_extension && width > 0 && width < sizeof(T) * 8) {
|
255
|
+
SignExtend<T>(dst, width);
|
241
256
|
}
|
242
257
|
}
|
243
258
|
};
|
@@ -40,6 +40,8 @@ enum class AggregateOrderDependent : uint8_t;
|
|
40
40
|
|
41
41
|
enum class AggregateType : uint8_t;
|
42
42
|
|
43
|
+
enum class AlterForeignKeyType : uint8_t;
|
44
|
+
|
43
45
|
enum class AlterScalarFunctionType : uint8_t;
|
44
46
|
|
45
47
|
enum class AlterTableFunctionType : uint8_t;
|
@@ -128,6 +130,8 @@ enum class FunctionNullHandling : uint8_t;
|
|
128
130
|
|
129
131
|
enum class FunctionSideEffects : uint8_t;
|
130
132
|
|
133
|
+
enum class IndexConstraintType : uint8_t;
|
134
|
+
|
131
135
|
enum class IndexType : uint8_t;
|
132
136
|
|
133
137
|
enum class InsertColumnOrder : uint8_t;
|
@@ -140,6 +144,8 @@ enum class JoinType : uint8_t;
|
|
140
144
|
|
141
145
|
enum class KeywordCategory : uint8_t;
|
142
146
|
|
147
|
+
enum class LoadType : uint8_t;
|
148
|
+
|
143
149
|
enum class LogicalOperatorType : uint8_t;
|
144
150
|
|
145
151
|
enum class LogicalTypeId : uint8_t;
|
@@ -174,6 +180,8 @@ enum class OrderType : uint8_t;
|
|
174
180
|
|
175
181
|
enum class OutputStream : uint8_t;
|
176
182
|
|
183
|
+
enum class ParseInfoType : uint8_t;
|
184
|
+
|
177
185
|
enum class ParserExtensionResultType : uint8_t;
|
178
186
|
|
179
187
|
enum class ParserMode : uint8_t;
|
@@ -214,6 +222,8 @@ enum class SetType : uint8_t;
|
|
214
222
|
|
215
223
|
enum class SimplifiedTokenType : uint8_t;
|
216
224
|
|
225
|
+
enum class SinkCombineResultType : uint8_t;
|
226
|
+
|
217
227
|
enum class SinkFinalizeType : uint8_t;
|
218
228
|
|
219
229
|
enum class SinkResultType : uint8_t;
|
@@ -283,6 +293,9 @@ const char* EnumUtil::ToChars<AggregateOrderDependent>(AggregateOrderDependent v
|
|
283
293
|
template<>
|
284
294
|
const char* EnumUtil::ToChars<AggregateType>(AggregateType value);
|
285
295
|
|
296
|
+
template<>
|
297
|
+
const char* EnumUtil::ToChars<AlterForeignKeyType>(AlterForeignKeyType value);
|
298
|
+
|
286
299
|
template<>
|
287
300
|
const char* EnumUtil::ToChars<AlterScalarFunctionType>(AlterScalarFunctionType value);
|
288
301
|
|
@@ -415,6 +428,9 @@ const char* EnumUtil::ToChars<FunctionNullHandling>(FunctionNullHandling value);
|
|
415
428
|
template<>
|
416
429
|
const char* EnumUtil::ToChars<FunctionSideEffects>(FunctionSideEffects value);
|
417
430
|
|
431
|
+
template<>
|
432
|
+
const char* EnumUtil::ToChars<IndexConstraintType>(IndexConstraintType value);
|
433
|
+
|
418
434
|
template<>
|
419
435
|
const char* EnumUtil::ToChars<IndexType>(IndexType value);
|
420
436
|
|
@@ -433,6 +449,9 @@ const char* EnumUtil::ToChars<JoinType>(JoinType value);
|
|
433
449
|
template<>
|
434
450
|
const char* EnumUtil::ToChars<KeywordCategory>(KeywordCategory value);
|
435
451
|
|
452
|
+
template<>
|
453
|
+
const char* EnumUtil::ToChars<LoadType>(LoadType value);
|
454
|
+
|
436
455
|
template<>
|
437
456
|
const char* EnumUtil::ToChars<LogicalOperatorType>(LogicalOperatorType value);
|
438
457
|
|
@@ -484,6 +503,9 @@ const char* EnumUtil::ToChars<OrderType>(OrderType value);
|
|
484
503
|
template<>
|
485
504
|
const char* EnumUtil::ToChars<OutputStream>(OutputStream value);
|
486
505
|
|
506
|
+
template<>
|
507
|
+
const char* EnumUtil::ToChars<ParseInfoType>(ParseInfoType value);
|
508
|
+
|
487
509
|
template<>
|
488
510
|
const char* EnumUtil::ToChars<ParserExtensionResultType>(ParserExtensionResultType value);
|
489
511
|
|
@@ -544,6 +566,9 @@ const char* EnumUtil::ToChars<SetType>(SetType value);
|
|
544
566
|
template<>
|
545
567
|
const char* EnumUtil::ToChars<SimplifiedTokenType>(SimplifiedTokenType value);
|
546
568
|
|
569
|
+
template<>
|
570
|
+
const char* EnumUtil::ToChars<SinkCombineResultType>(SinkCombineResultType value);
|
571
|
+
|
547
572
|
template<>
|
548
573
|
const char* EnumUtil::ToChars<SinkFinalizeType>(SinkFinalizeType value);
|
549
574
|
|
@@ -641,6 +666,9 @@ AggregateOrderDependent EnumUtil::FromString<AggregateOrderDependent>(const char
|
|
641
666
|
template<>
|
642
667
|
AggregateType EnumUtil::FromString<AggregateType>(const char *value);
|
643
668
|
|
669
|
+
template<>
|
670
|
+
AlterForeignKeyType EnumUtil::FromString<AlterForeignKeyType>(const char *value);
|
671
|
+
|
644
672
|
template<>
|
645
673
|
AlterScalarFunctionType EnumUtil::FromString<AlterScalarFunctionType>(const char *value);
|
646
674
|
|
@@ -773,6 +801,9 @@ FunctionNullHandling EnumUtil::FromString<FunctionNullHandling>(const char *valu
|
|
773
801
|
template<>
|
774
802
|
FunctionSideEffects EnumUtil::FromString<FunctionSideEffects>(const char *value);
|
775
803
|
|
804
|
+
template<>
|
805
|
+
IndexConstraintType EnumUtil::FromString<IndexConstraintType>(const char *value);
|
806
|
+
|
776
807
|
template<>
|
777
808
|
IndexType EnumUtil::FromString<IndexType>(const char *value);
|
778
809
|
|
@@ -791,6 +822,9 @@ JoinType EnumUtil::FromString<JoinType>(const char *value);
|
|
791
822
|
template<>
|
792
823
|
KeywordCategory EnumUtil::FromString<KeywordCategory>(const char *value);
|
793
824
|
|
825
|
+
template<>
|
826
|
+
LoadType EnumUtil::FromString<LoadType>(const char *value);
|
827
|
+
|
794
828
|
template<>
|
795
829
|
LogicalOperatorType EnumUtil::FromString<LogicalOperatorType>(const char *value);
|
796
830
|
|
@@ -842,6 +876,9 @@ OrderType EnumUtil::FromString<OrderType>(const char *value);
|
|
842
876
|
template<>
|
843
877
|
OutputStream EnumUtil::FromString<OutputStream>(const char *value);
|
844
878
|
|
879
|
+
template<>
|
880
|
+
ParseInfoType EnumUtil::FromString<ParseInfoType>(const char *value);
|
881
|
+
|
845
882
|
template<>
|
846
883
|
ParserExtensionResultType EnumUtil::FromString<ParserExtensionResultType>(const char *value);
|
847
884
|
|
@@ -902,6 +939,9 @@ SetType EnumUtil::FromString<SetType>(const char *value);
|
|
902
939
|
template<>
|
903
940
|
SimplifiedTokenType EnumUtil::FromString<SimplifiedTokenType>(const char *value);
|
904
941
|
|
942
|
+
template<>
|
943
|
+
SinkCombineResultType EnumUtil::FromString<SinkCombineResultType>(const char *value);
|
944
|
+
|
905
945
|
template<>
|
906
946
|
SinkFinalizeType EnumUtil::FromString<SinkFinalizeType>(const char *value);
|
907
947
|
|
@@ -23,7 +23,7 @@ enum class IndexType : uint8_t {
|
|
23
23
|
//===--------------------------------------------------------------------===//
|
24
24
|
// Index Constraint Types
|
25
25
|
//===--------------------------------------------------------------------===//
|
26
|
-
enum IndexConstraintType : uint8_t {
|
26
|
+
enum class IndexConstraintType : uint8_t {
|
27
27
|
NONE = 0, // index is an index don't built to any constraint
|
28
28
|
UNIQUE = 1, // index is an index built to enforce a UNIQUE constraint
|
29
29
|
PRIMARY = 2, // index is an index built to enforce a PRIMARY KEY constraint
|
@@ -46,10 +46,14 @@ enum class SourceResultType : uint8_t { HAVE_MORE_OUTPUT, FINISHED, BLOCKED };
|
|
46
46
|
//! BLOCKED means the sink is currently blocked, e.g. by some async I/O.
|
47
47
|
enum class SinkResultType : uint8_t { NEED_MORE_INPUT, FINISHED, BLOCKED };
|
48
48
|
|
49
|
+
// todo comment
|
50
|
+
enum class SinkCombineResultType : uint8_t { FINISHED, BLOCKED };
|
51
|
+
|
49
52
|
//! The SinkFinalizeType is used to indicate the result of a Finalize call on a sink
|
50
53
|
//! There are two possible results:
|
51
54
|
//! READY means the sink is ready for further processing
|
52
55
|
//! NO_OUTPUT_POSSIBLE means the sink will never provide output, and any pipelines involving the sink can be skipped
|
53
|
-
|
56
|
+
//! BLOCKED means the finalize call to the sink is currently blocked, e.g. by some async I/O.
|
57
|
+
enum class SinkFinalizeType : uint8_t { READY, NO_OUTPUT_POSSIBLE, BLOCKED };
|
54
58
|
|
55
59
|
} // namespace duckdb
|
@@ -3,6 +3,7 @@
|
|
3
3
|
#include "duckdb/common/winapi.hpp"
|
4
4
|
#include "duckdb/common/string.hpp"
|
5
5
|
#include <stdint.h>
|
6
|
+
#include "duckdb/common/typedefs.hpp"
|
6
7
|
|
7
8
|
namespace duckdb {
|
8
9
|
|
@@ -58,6 +59,20 @@ public:
|
|
58
59
|
DUCKDB_API hugeint_t &operator&=(const hugeint_t &rhs);
|
59
60
|
DUCKDB_API hugeint_t &operator|=(const hugeint_t &rhs);
|
60
61
|
DUCKDB_API hugeint_t &operator^=(const hugeint_t &rhs);
|
62
|
+
|
63
|
+
// boolean operators
|
64
|
+
DUCKDB_API explicit operator bool() const;
|
65
|
+
DUCKDB_API bool operator!() const;
|
66
|
+
|
67
|
+
// cast operators
|
68
|
+
DUCKDB_API explicit operator uint8_t() const;
|
69
|
+
DUCKDB_API explicit operator uint16_t() const;
|
70
|
+
DUCKDB_API explicit operator uint32_t() const;
|
71
|
+
DUCKDB_API explicit operator uint64_t() const;
|
72
|
+
DUCKDB_API explicit operator int8_t() const;
|
73
|
+
DUCKDB_API explicit operator int16_t() const;
|
74
|
+
DUCKDB_API explicit operator int32_t() const;
|
75
|
+
DUCKDB_API explicit operator int64_t() const;
|
61
76
|
};
|
62
77
|
|
63
78
|
} // namespace duckdb
|
@@ -10,6 +10,8 @@
|
|
10
10
|
|
11
11
|
#include "duckdb/common/constants.hpp"
|
12
12
|
#include "duckdb/common/vector.hpp"
|
13
|
+
#include "duckdb/common/serializer/format_serializer.hpp"
|
14
|
+
#include "duckdb/common/serializer/format_deserializer.hpp"
|
13
15
|
|
14
16
|
namespace duckdb {
|
15
17
|
|
@@ -59,6 +61,16 @@ public:
|
|
59
61
|
return internal_vector.end();
|
60
62
|
}
|
61
63
|
|
64
|
+
void FormatSerialize(FormatSerializer &serializer) const {
|
65
|
+
serializer.WriteProperty("internal_vector", internal_vector);
|
66
|
+
}
|
67
|
+
|
68
|
+
static IndexVector<T, INDEX_TYPE> FormatDeserialize(FormatDeserializer &deserializer) {
|
69
|
+
IndexVector<T, INDEX_TYPE> result;
|
70
|
+
deserializer.ReadProperty("internal_vector", result.internal_vector);
|
71
|
+
return result;
|
72
|
+
}
|
73
|
+
|
62
74
|
private:
|
63
75
|
vector<T> internal_vector;
|
64
76
|
};
|