duckdb 0.7.2-dev1457.0 → 0.7.2-dev1533.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 +8 -8
- package/package.json +1 -1
- package/src/duckdb/extension/icu/icu-dateadd.cpp +2 -2
- package/src/duckdb/extension/icu/icu-datepart.cpp +3 -3
- package/src/duckdb/extension/icu/icu-datesub.cpp +2 -2
- package/src/duckdb/extension/icu/icu-datetrunc.cpp +1 -1
- package/src/duckdb/extension/icu/icu-extension.cpp +3 -3
- package/src/duckdb/extension/icu/icu-list-range.cpp +1 -1
- package/src/duckdb/extension/icu/icu-makedate.cpp +1 -1
- package/src/duckdb/extension/icu/icu-strptime.cpp +7 -7
- package/src/duckdb/extension/icu/icu-timebucket.cpp +6 -6
- package/src/duckdb/extension/icu/icu-timezone.cpp +4 -4
- package/src/duckdb/extension/json/include/json_executors.hpp +2 -2
- package/src/duckdb/extension/json/json_functions/copy_json.cpp +4 -4
- package/src/duckdb/extension/json/json_functions/json_create.cpp +3 -3
- package/src/duckdb/extension/json/json_functions/json_serialize_sql.cpp +3 -3
- package/src/duckdb/extension/json/json_functions.cpp +2 -2
- package/src/duckdb/extension/parquet/parquet-extension.cpp +28 -28
- package/src/duckdb/extension/parquet/parquet_metadata.cpp +3 -3
- package/src/duckdb/src/catalog/catalog_entry/duck_index_entry.cpp +2 -2
- package/src/duckdb/src/catalog/catalog_entry/duck_schema_entry.cpp +9 -9
- package/src/duckdb/src/catalog/catalog_entry/duck_table_entry.cpp +17 -17
- package/src/duckdb/src/catalog/catalog_entry/index_catalog_entry.cpp +3 -3
- package/src/duckdb/src/catalog/catalog_entry/scalar_macro_catalog_entry.cpp +2 -2
- package/src/duckdb/src/catalog/catalog_entry/schema_catalog_entry.cpp +2 -2
- package/src/duckdb/src/catalog/catalog_entry/sequence_catalog_entry.cpp +2 -2
- package/src/duckdb/src/catalog/catalog_entry/table_catalog_entry.cpp +5 -5
- package/src/duckdb/src/catalog/catalog_entry/type_catalog_entry.cpp +2 -2
- package/src/duckdb/src/catalog/catalog_entry/view_catalog_entry.cpp +3 -3
- package/src/duckdb/src/catalog/catalog_entry.cpp +2 -2
- package/src/duckdb/src/catalog/catalog_set.cpp +28 -28
- package/src/duckdb/src/catalog/default/default_functions.cpp +2 -1
- package/src/duckdb/src/catalog/dependency_manager.cpp +4 -4
- package/src/duckdb/src/common/enums/logical_operator_type.cpp +2 -0
- package/src/duckdb/src/common/enums/physical_operator_type.cpp +2 -0
- package/src/duckdb/src/common/hive_partitioning.cpp +1 -1
- package/src/duckdb/src/common/multi_file_reader.cpp +1 -1
- package/src/duckdb/src/common/row_operations/row_aggregate.cpp +3 -0
- package/src/duckdb/src/common/string_util.cpp +24 -2
- package/src/duckdb/src/common/tree_renderer.cpp +2 -4
- package/src/duckdb/src/common/types.cpp +3 -1
- package/src/duckdb/src/execution/column_binding_resolver.cpp +5 -5
- package/src/duckdb/src/execution/expression_executor.cpp +4 -3
- package/src/duckdb/src/execution/expression_executor_state.cpp +1 -1
- package/src/duckdb/src/execution/index/art/art.cpp +6 -8
- package/src/duckdb/src/execution/operator/aggregate/distinct_aggregate_data.cpp +7 -7
- package/src/duckdb/src/execution/operator/aggregate/grouped_aggregate_data.cpp +2 -2
- package/src/duckdb/src/execution/operator/aggregate/physical_hash_aggregate.cpp +33 -33
- package/src/duckdb/src/execution/operator/aggregate/physical_perfecthash_aggregate.cpp +13 -13
- package/src/duckdb/src/execution/operator/aggregate/physical_streaming_window.cpp +3 -3
- package/src/duckdb/src/execution/operator/aggregate/physical_ungrouped_aggregate.cpp +20 -20
- package/src/duckdb/src/execution/operator/aggregate/physical_window.cpp +12 -12
- package/src/duckdb/src/execution/operator/helper/physical_batch_collector.cpp +5 -5
- package/src/duckdb/src/execution/operator/helper/physical_explain_analyze.cpp +2 -2
- package/src/duckdb/src/execution/operator/helper/physical_limit.cpp +5 -5
- package/src/duckdb/src/execution/operator/helper/physical_limit_percent.cpp +4 -4
- package/src/duckdb/src/execution/operator/helper/physical_materialized_collector.cpp +4 -4
- package/src/duckdb/src/execution/operator/helper/physical_reservoir_sample.cpp +2 -2
- package/src/duckdb/src/execution/operator/helper/physical_streaming_limit.cpp +2 -2
- package/src/duckdb/src/execution/operator/helper/physical_streaming_sample.cpp +2 -2
- package/src/duckdb/src/execution/operator/helper/physical_vacuum.cpp +4 -4
- package/src/duckdb/src/execution/operator/join/physical_blockwise_nl_join.cpp +8 -8
- package/src/duckdb/src/execution/operator/join/physical_cross_product.cpp +3 -3
- package/src/duckdb/src/execution/operator/join/physical_delim_join.cpp +3 -3
- package/src/duckdb/src/execution/operator/join/physical_hash_join.cpp +12 -12
- package/src/duckdb/src/execution/operator/join/physical_iejoin.cpp +12 -12
- package/src/duckdb/src/execution/operator/join/physical_index_join.cpp +6 -5
- package/src/duckdb/src/execution/operator/join/physical_join.cpp +2 -2
- package/src/duckdb/src/execution/operator/join/physical_nested_loop_join.cpp +13 -13
- package/src/duckdb/src/execution/operator/join/physical_piecewise_merge_join.cpp +10 -10
- package/src/duckdb/src/execution/operator/join/physical_positional_join.cpp +3 -3
- package/src/duckdb/src/execution/operator/order/physical_order.cpp +11 -11
- package/src/duckdb/src/execution/operator/order/physical_top_n.cpp +6 -6
- package/src/duckdb/src/execution/operator/persistent/physical_batch_insert.cpp +7 -7
- package/src/duckdb/src/execution/operator/persistent/physical_copy_to_file.cpp +8 -8
- package/src/duckdb/src/execution/operator/persistent/physical_delete.cpp +5 -5
- package/src/duckdb/src/execution/operator/persistent/physical_export.cpp +1 -1
- package/src/duckdb/src/execution/operator/persistent/physical_insert.cpp +8 -8
- package/src/duckdb/src/execution/operator/persistent/physical_update.cpp +7 -7
- package/src/duckdb/src/execution/operator/projection/physical_pivot.cpp +81 -0
- package/src/duckdb/src/execution/operator/projection/physical_tableinout_function.cpp +5 -5
- package/src/duckdb/src/execution/operator/projection/physical_unnest.cpp +4 -5
- package/src/duckdb/src/execution/operator/scan/physical_column_data_scan.cpp +1 -1
- package/src/duckdb/src/execution/operator/scan/physical_positional_scan.cpp +4 -4
- package/src/duckdb/src/execution/operator/scan/physical_table_scan.cpp +7 -7
- package/src/duckdb/src/execution/operator/schema/physical_alter.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_attach.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_create_function.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_create_index.cpp +8 -7
- package/src/duckdb/src/execution/operator/schema/physical_create_schema.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_create_sequence.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_create_table.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_create_type.cpp +3 -3
- package/src/duckdb/src/execution/operator/schema/physical_create_view.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_detach.cpp +1 -1
- package/src/duckdb/src/execution/operator/schema/physical_drop.cpp +1 -1
- package/src/duckdb/src/execution/operator/set/physical_recursive_cte.cpp +2 -2
- package/src/duckdb/src/execution/physical_operator.cpp +2 -2
- package/src/duckdb/src/execution/physical_plan/plan_aggregate.cpp +4 -4
- package/src/duckdb/src/execution/physical_plan/plan_comparison_join.cpp +2 -2
- package/src/duckdb/src/execution/physical_plan/plan_create_index.cpp +1 -1
- package/src/duckdb/src/execution/physical_plan/plan_delete.cpp +1 -1
- package/src/duckdb/src/execution/physical_plan/plan_delim_join.cpp +2 -2
- package/src/duckdb/src/execution/physical_plan/plan_distinct.cpp +4 -1
- package/src/duckdb/src/execution/physical_plan/plan_pivot.cpp +14 -0
- package/src/duckdb/src/execution/physical_plan/plan_projection.cpp +1 -1
- package/src/duckdb/src/execution/physical_plan/plan_window.cpp +8 -8
- package/src/duckdb/src/execution/physical_plan_generator.cpp +49 -42
- package/src/duckdb/src/execution/radix_partitioned_hashtable.cpp +14 -14
- package/src/duckdb/src/function/aggregate/algebraic/avg.cpp +2 -2
- package/src/duckdb/src/function/aggregate/distributive/bitstring_agg.cpp +1 -1
- package/src/duckdb/src/function/aggregate/distributive/string_agg.cpp +2 -2
- package/src/duckdb/src/function/aggregate/holistic/approximate_quantile.cpp +1 -1
- package/src/duckdb/src/function/aggregate/holistic/quantile.cpp +1 -1
- package/src/duckdb/src/function/aggregate/holistic/reservoir_quantile.cpp +1 -1
- package/src/duckdb/src/function/aggregate/nested/list.cpp +3 -3
- package/src/duckdb/src/function/cast/enum_casts.cpp +3 -3
- package/src/duckdb/src/function/cast/list_casts.cpp +2 -2
- package/src/duckdb/src/function/cast/string_cast.cpp +6 -6
- package/src/duckdb/src/function/cast/struct_cast.cpp +4 -4
- package/src/duckdb/src/function/cast/union_casts.cpp +6 -6
- package/src/duckdb/src/function/function.cpp +4 -4
- package/src/duckdb/src/function/function_binder.cpp +2 -1
- package/src/duckdb/src/function/macro_function.cpp +3 -3
- package/src/duckdb/src/function/pragma/pragma_queries.cpp +1 -1
- package/src/duckdb/src/function/pragma_function.cpp +1 -1
- package/src/duckdb/src/function/scalar/date/date_part.cpp +1 -1
- package/src/duckdb/src/function/scalar/date/strftime.cpp +6 -6
- package/src/duckdb/src/function/scalar/generic/alias.cpp +1 -1
- package/src/duckdb/src/function/scalar/generic/constant_or_null.cpp +3 -3
- package/src/duckdb/src/function/scalar/generic/current_setting.cpp +2 -2
- package/src/duckdb/src/function/scalar/generic/stats.cpp +3 -3
- package/src/duckdb/src/function/scalar/list/list_aggregates.cpp +5 -5
- package/src/duckdb/src/function/scalar/list/list_lambdas.cpp +3 -3
- package/src/duckdb/src/function/scalar/list/list_sort.cpp +3 -3
- package/src/duckdb/src/function/scalar/math/numeric.cpp +3 -3
- package/src/duckdb/src/function/scalar/math/random.cpp +2 -2
- package/src/duckdb/src/function/scalar/math/setseed.cpp +2 -2
- package/src/duckdb/src/function/scalar/operators/arithmetic.cpp +2 -2
- package/src/duckdb/src/function/scalar/sequence/nextval.cpp +4 -4
- package/src/duckdb/src/function/scalar/string/like.cpp +1 -1
- package/src/duckdb/src/function/scalar/string/regexp/regexp_extract_all.cpp +5 -5
- package/src/duckdb/src/function/scalar/string/regexp.cpp +11 -11
- package/src/duckdb/src/function/scalar/string/string_split.cpp +3 -3
- package/src/duckdb/src/function/scalar/struct/struct_extract.cpp +3 -3
- package/src/duckdb/src/function/scalar/struct/struct_pack.cpp +2 -2
- package/src/duckdb/src/function/scalar/system/aggregate_export.cpp +2 -2
- package/src/duckdb/src/function/scalar/union/union_extract.cpp +2 -2
- package/src/duckdb/src/function/scalar_macro_function.cpp +3 -3
- package/src/duckdb/src/function/table/arrow.cpp +5 -5
- package/src/duckdb/src/function/table/checkpoint.cpp +1 -1
- package/src/duckdb/src/function/table/glob.cpp +1 -1
- package/src/duckdb/src/function/table/pragma_detailed_profiling_output.cpp +1 -1
- package/src/duckdb/src/function/table/pragma_last_profiling_output.cpp +1 -1
- package/src/duckdb/src/function/table/range.cpp +5 -5
- package/src/duckdb/src/function/table/read_csv.cpp +10 -10
- package/src/duckdb/src/function/table/repeat.cpp +1 -1
- package/src/duckdb/src/function/table/system/duckdb_constraints.cpp +12 -12
- package/src/duckdb/src/function/table/system/duckdb_databases.cpp +1 -1
- package/src/duckdb/src/function/table/system/duckdb_functions.cpp +2 -2
- package/src/duckdb/src/function/table/system/duckdb_indexes.cpp +1 -1
- package/src/duckdb/src/function/table/system/duckdb_sequences.cpp +1 -1
- package/src/duckdb/src/function/table/system/duckdb_tables.cpp +2 -2
- package/src/duckdb/src/function/table/system/duckdb_views.cpp +1 -1
- package/src/duckdb/src/function/table/system/pragma_storage_info.cpp +1 -1
- package/src/duckdb/src/function/table/system/pragma_table_info.cpp +3 -3
- package/src/duckdb/src/function/table/system/test_vector_types.cpp +1 -1
- package/src/duckdb/src/function/table/table_scan.cpp +31 -31
- package/src/duckdb/src/function/table/unnest.cpp +4 -4
- package/src/duckdb/src/function/table/version/pragma_version.cpp +2 -2
- package/src/duckdb/src/function/table_macro_function.cpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog.hpp +13 -0
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/duck_index_entry.hpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/duck_table_entry.hpp +1 -1
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/index_catalog_entry.hpp +4 -4
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/macro_catalog_entry.hpp +3 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/scalar_macro_catalog_entry.hpp +1 -1
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/schema_catalog_entry.hpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/sequence_catalog_entry.hpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/table_catalog_entry.hpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/table_macro_catalog_entry.hpp +1 -1
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/type_catalog_entry.hpp +2 -2
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry/view_catalog_entry.hpp +3 -3
- package/src/duckdb/src/include/duckdb/catalog/catalog_entry.hpp +14 -3
- package/src/duckdb/src/include/duckdb/catalog/catalog_set.hpp +5 -5
- package/src/duckdb/src/include/duckdb/common/case_insensitive_map.hpp +2 -3
- package/src/duckdb/src/include/duckdb/common/enums/logical_operator_type.hpp +1 -0
- package/src/duckdb/src/include/duckdb/common/enums/physical_operator_type.hpp +2 -0
- package/src/duckdb/src/include/duckdb/common/multi_file_reader_options.hpp +1 -1
- package/src/duckdb/src/include/duckdb/common/string_util.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/index/art/art.hpp +1 -1
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_hash_aggregate.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_perfecthash_aggregate.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_streaming_window.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_ungrouped_aggregate.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/aggregate/physical_window.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/filter/physical_filter.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_execute.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_explain_analyze.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_limit.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_limit_percent.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_load.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_pragma.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_prepare.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_reset.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_set.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_streaming_limit.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_streaming_sample.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_transaction.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/helper/physical_vacuum.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_blockwise_nl_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_cross_product.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_delim_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_hash_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_iejoin.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_index_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_nested_loop_join.hpp +3 -4
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_piecewise_merge_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/join/physical_positional_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/order/physical_order.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/order/physical_top_n.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_batch_insert.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_copy_to_file.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_delete.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_export.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_insert.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_update.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/projection/physical_pivot.hpp +38 -0
- package/src/duckdb/src/include/duckdb/execution/operator/projection/physical_projection.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/projection/physical_tableinout_function.hpp +4 -2
- package/src/duckdb/src/include/duckdb/execution/operator/projection/physical_unnest.hpp +3 -1
- package/src/duckdb/src/include/duckdb/execution/operator/scan/physical_column_data_scan.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/scan/physical_dummy_scan.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/scan/physical_empty_result.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/scan/physical_expression_scan.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/scan/physical_positional_scan.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/scan/physical_table_scan.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_alter.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_attach.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_function.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_index.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_schema.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_sequence.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_table.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_type.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_view.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_detach.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_drop.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/set/physical_recursive_cte.hpp +3 -0
- package/src/duckdb/src/include/duckdb/execution/operator/set/physical_union.hpp +4 -0
- package/src/duckdb/src/include/duckdb/execution/physical_operator.hpp +18 -57
- package/src/duckdb/src/include/duckdb/execution/physical_operator_states.hpp +150 -0
- package/src/duckdb/src/include/duckdb/execution/physical_plan_generator.hpp +1 -0
- package/src/duckdb/src/include/duckdb/function/cast/default_casts.hpp +11 -0
- package/src/duckdb/src/include/duckdb/function/copy_function.hpp +22 -0
- package/src/duckdb/src/include/duckdb/function/function.hpp +20 -4
- package/src/duckdb/src/include/duckdb/function/macro_function.hpp +3 -3
- package/src/duckdb/src/include/duckdb/function/pragma_function.hpp +1 -1
- package/src/duckdb/src/include/duckdb/function/scalar/nested_functions.hpp +1 -1
- package/src/duckdb/src/include/duckdb/function/scalar_function.hpp +11 -0
- package/src/duckdb/src/include/duckdb/function/scalar_macro_function.hpp +2 -2
- package/src/duckdb/src/include/duckdb/function/table_function.hpp +22 -0
- package/src/duckdb/src/include/duckdb/function/table_macro_function.hpp +3 -3
- package/src/duckdb/src/include/duckdb/main/client_config.hpp +3 -2
- package/src/duckdb/src/include/duckdb/main/settings.hpp +10 -0
- package/src/duckdb/src/include/duckdb/optimizer/rule/like_optimizations.hpp +1 -1
- package/src/duckdb/src/include/duckdb/parser/base_expression.hpp +18 -0
- package/src/duckdb/src/include/duckdb/parser/constraint.hpp +18 -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 +3 -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 +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/between_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/bound_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/case_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/cast_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/collate_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/columnref_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/comparison_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/conjunction_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/constant_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/default_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/function_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/lambda_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/operator_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/parameter_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/positional_reference_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/star_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/subquery_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/expression/window_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/query_node/list.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/query_node/recursive_cte_node.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/query_node/select_node.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/query_node/set_operation_node.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/query_node.hpp +18 -0
- package/src/duckdb/src/include/duckdb/parser/sql_statement.hpp +18 -0
- package/src/duckdb/src/include/duckdb/parser/statement/alter_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/attach_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/call_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/copy_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/create_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/delete_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/detach_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/drop_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/execute_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/explain_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/export_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/extension_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/insert_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/list.hpp +1 -0
- package/src/duckdb/src/include/duckdb/parser/statement/load_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/logical_plan_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/multi_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/pragma_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/prepare_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/relation_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/select_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/set_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/show_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/transaction_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/update_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/statement/vacuum_statement.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/basetableref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/emptytableref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/expressionlistref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/joinref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/pivotref.hpp +14 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/subqueryref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref/table_function_ref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/parser/tableref.hpp +17 -0
- package/src/duckdb/src/include/duckdb/planner/bind_context.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/binder.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/bound_constraint.hpp +18 -0
- package/src/duckdb/src/include/duckdb/planner/bound_query_node.hpp +17 -0
- package/src/duckdb/src/include/duckdb/planner/bound_result_modifier.hpp +5 -1
- package/src/duckdb/src/include/duckdb/planner/bound_tableref.hpp +17 -0
- package/src/duckdb/src/include/duckdb/planner/bound_tokens.hpp +1 -0
- package/src/duckdb/src/include/duckdb/planner/constraints/bound_check_constraint.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/constraints/bound_foreign_key_constraint.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/constraints/bound_not_null_constraint.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/constraints/bound_unique_constraint.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_aggregate_expression.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_between_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_case_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_cast_expression.hpp +3 -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_function_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_lambda_expression.hpp +3 -0
- 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_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_reference_expression.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/expression/bound_subquery_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/bound_window_expression.hpp +4 -1
- package/src/duckdb/src/include/duckdb/planner/expression_binder/table_function_binder.hpp +1 -1
- package/src/duckdb/src/include/duckdb/planner/expression_binder.hpp +2 -0
- package/src/duckdb/src/include/duckdb/planner/logical_operator.hpp +17 -0
- package/src/duckdb/src/include/duckdb/planner/logical_tokens.hpp +1 -0
- package/src/duckdb/src/include/duckdb/planner/operator/list.hpp +1 -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_asof_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_column_data_get.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_comparison_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_copy_to_file.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_create.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_create_index.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_create_table.hpp +3 -0
- 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 +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_delete.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_delim_get.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_delim_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_distinct.hpp +12 -4
- package/src/duckdb/src/include/duckdb/planner/operator/logical_dummy_scan.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_empty_result.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_execute.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_explain.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_export.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_expression_get.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_extension_operator.hpp +4 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_filter.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_get.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_insert.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_join.hpp +3 -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_order.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_pivot.hpp +36 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_positional_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_pragma.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_prepare.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 +9 -5
- package/src/duckdb/src/include/duckdb/planner/operator/logical_reset.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_sample.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_set.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_set_operation.hpp +3 -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 +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_unconditional_join.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_unnest.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_update.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_window.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/query_node/bound_recursive_cte_node.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/query_node/bound_select_node.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/query_node/bound_set_operation_node.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/query_node/list.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_basetableref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_cteref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_dummytableref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_expressionlistref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_joinref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_pivotref.hpp +43 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_pos_join_ref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_subqueryref.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/bound_table_function.hpp +3 -0
- package/src/duckdb/src/include/duckdb/planner/tableref/list.hpp +1 -0
- package/src/duckdb/src/include/duckdb/storage/index.hpp +15 -2
- package/src/duckdb/src/include/duckdb/storage/write_ahead_log.hpp +17 -17
- package/src/duckdb/src/include/duckdb/transaction/commit_state.hpp +1 -1
- package/src/duckdb/src/main/capi/table_function-c.cpp +9 -9
- package/src/duckdb/src/main/client_context.cpp +1 -1
- package/src/duckdb/src/main/config.cpp +1 -0
- package/src/duckdb/src/main/query_profiler.cpp +2 -2
- package/src/duckdb/src/main/relation/aggregate_relation.cpp +1 -1
- package/src/duckdb/src/main/relation/filter_relation.cpp +1 -1
- package/src/duckdb/src/main/relation/projection_relation.cpp +1 -1
- package/src/duckdb/src/main/relation.cpp +1 -1
- package/src/duckdb/src/main/settings/settings.cpp +17 -1
- package/src/duckdb/src/optimizer/column_lifetime_analyzer.cpp +3 -3
- package/src/duckdb/src/optimizer/common_aggregate_optimizer.cpp +1 -1
- package/src/duckdb/src/optimizer/cse_optimizer.cpp +1 -1
- package/src/duckdb/src/optimizer/deliminator.cpp +11 -11
- package/src/duckdb/src/optimizer/expression_heuristics.cpp +11 -11
- package/src/duckdb/src/optimizer/expression_rewriter.cpp +1 -1
- package/src/duckdb/src/optimizer/filter_combiner.cpp +40 -38
- package/src/duckdb/src/optimizer/filter_pullup.cpp +2 -2
- package/src/duckdb/src/optimizer/filter_pushdown.cpp +1 -1
- package/src/duckdb/src/optimizer/join_order/cardinality_estimator.cpp +8 -8
- package/src/duckdb/src/optimizer/join_order/join_order_optimizer.cpp +24 -24
- package/src/duckdb/src/optimizer/matcher/expression_matcher.cpp +12 -12
- package/src/duckdb/src/optimizer/pullup/pullup_filter.cpp +1 -1
- package/src/duckdb/src/optimizer/pullup/pullup_projection.cpp +2 -2
- package/src/duckdb/src/optimizer/pullup/pullup_set_operation.cpp +3 -3
- package/src/duckdb/src/optimizer/pushdown/pushdown_aggregate.cpp +3 -3
- package/src/duckdb/src/optimizer/pushdown/pushdown_filter.cpp +1 -1
- package/src/duckdb/src/optimizer/pushdown/pushdown_get.cpp +1 -1
- package/src/duckdb/src/optimizer/pushdown/pushdown_inner_join.cpp +3 -3
- package/src/duckdb/src/optimizer/pushdown/pushdown_left_join.cpp +3 -3
- package/src/duckdb/src/optimizer/pushdown/pushdown_limit.cpp +1 -1
- package/src/duckdb/src/optimizer/pushdown/pushdown_mark_join.cpp +3 -3
- package/src/duckdb/src/optimizer/pushdown/pushdown_projection.cpp +2 -2
- package/src/duckdb/src/optimizer/pushdown/pushdown_set_operation.cpp +4 -4
- package/src/duckdb/src/optimizer/pushdown/pushdown_single_join.cpp +1 -1
- package/src/duckdb/src/optimizer/regex_range_filter.cpp +2 -2
- package/src/duckdb/src/optimizer/remove_unused_columns.cpp +13 -9
- package/src/duckdb/src/optimizer/rule/arithmetic_simplification.cpp +20 -20
- package/src/duckdb/src/optimizer/rule/case_simplification.cpp +8 -8
- package/src/duckdb/src/optimizer/rule/comparison_simplification.cpp +14 -14
- package/src/duckdb/src/optimizer/rule/conjunction_simplification.cpp +5 -5
- package/src/duckdb/src/optimizer/rule/date_part_simplification.cpp +2 -2
- package/src/duckdb/src/optimizer/rule/distributivity.cpp +16 -16
- package/src/duckdb/src/optimizer/rule/empty_needle_removal.cpp +4 -5
- package/src/duckdb/src/optimizer/rule/enum_comparison.cpp +8 -9
- package/src/duckdb/src/optimizer/rule/in_clause_simplification_rule.cpp +13 -13
- package/src/duckdb/src/optimizer/rule/like_optimizations.cpp +12 -12
- package/src/duckdb/src/optimizer/rule/move_constants.cpp +31 -31
- package/src/duckdb/src/optimizer/rule/ordered_aggregate_optimizer.cpp +4 -4
- package/src/duckdb/src/optimizer/rule/regex_optimizations.cpp +10 -10
- package/src/duckdb/src/optimizer/statistics/operator/propagate_filter.cpp +9 -8
- package/src/duckdb/src/optimizer/statistics/operator/propagate_join.cpp +2 -2
- package/src/duckdb/src/optimizer/statistics_propagator.cpp +31 -20
- package/src/duckdb/src/optimizer/topn_optimizer.cpp +2 -2
- package/src/duckdb/src/optimizer/unnest_rewriter.cpp +13 -13
- package/src/duckdb/src/parser/column_definition.cpp +3 -3
- package/src/duckdb/src/parser/expression/columnref_expression.cpp +2 -5
- package/src/duckdb/src/parser/expression/conjunction_expression.cpp +1 -1
- package/src/duckdb/src/parser/expression/constant_expression.cpp +1 -1
- package/src/duckdb/src/parser/parsed_data/create_view_info.cpp +1 -1
- package/src/duckdb/src/parser/parsed_expression_iterator.cpp +20 -20
- package/src/duckdb/src/parser/parser.cpp +10 -10
- package/src/duckdb/src/parser/query_node/recursive_cte_node.cpp +4 -4
- package/src/duckdb/src/parser/query_node/select_node.cpp +10 -10
- package/src/duckdb/src/parser/query_node/set_operation_node.cpp +4 -4
- package/src/duckdb/src/parser/statement/insert_statement.cpp +1 -1
- package/src/duckdb/src/parser/statement/select_statement.cpp +2 -2
- package/src/duckdb/src/parser/transform/expression/transform_array_access.cpp +1 -1
- package/src/duckdb/src/parser/transform/expression/transform_columnref.cpp +3 -3
- package/src/duckdb/src/parser/transform/expression/transform_function.cpp +2 -42
- package/src/duckdb/src/parser/transform/expression/transform_operator.cpp +1 -1
- package/src/duckdb/src/parser/transform/helpers/transform_groupby.cpp +1 -1
- package/src/duckdb/src/parser/transform/statement/transform_create_type.cpp +0 -1
- package/src/duckdb/src/parser/transform/statement/transform_pivot_stmt.cpp +5 -2
- package/src/duckdb/src/parser/transform/statement/transform_pragma.cpp +5 -5
- package/src/duckdb/src/parser/transform/statement/transform_select_node.cpp +20 -20
- package/src/duckdb/src/parser/transform/tableref/transform_pivot.cpp +3 -3
- package/src/duckdb/src/planner/bind_context.cpp +11 -0
- package/src/duckdb/src/planner/binder/expression/bind_columnref_expression.cpp +47 -4
- package/src/duckdb/src/planner/binder/expression/bind_function_expression.cpp +5 -6
- package/src/duckdb/src/planner/binder/expression/bind_lambda.cpp +2 -2
- package/src/duckdb/src/planner/binder/expression/bind_macro_expression.cpp +3 -3
- package/src/duckdb/src/planner/binder/expression/bind_star_expression.cpp +8 -8
- package/src/duckdb/src/planner/binder/query_node/bind_select_node.cpp +23 -29
- package/src/duckdb/src/planner/binder/query_node/bind_setop_node.cpp +2 -2
- package/src/duckdb/src/planner/binder/query_node/bind_table_macro_node.cpp +1 -1
- package/src/duckdb/src/planner/binder/query_node/plan_query_node.cpp +3 -3
- package/src/duckdb/src/planner/binder/query_node/plan_recursive_cte_node.cpp +2 -3
- package/src/duckdb/src/planner/binder/query_node/plan_select_node.cpp +0 -2
- package/src/duckdb/src/planner/binder/query_node/plan_subquery.cpp +1 -1
- package/src/duckdb/src/planner/binder/statement/bind_call.cpp +3 -2
- package/src/duckdb/src/planner/binder/statement/bind_copy.cpp +1 -1
- package/src/duckdb/src/planner/binder/statement/bind_create.cpp +17 -16
- package/src/duckdb/src/planner/binder/statement/bind_create_table.cpp +7 -6
- package/src/duckdb/src/planner/binder/statement/bind_delete.cpp +3 -2
- package/src/duckdb/src/planner/binder/statement/bind_export.cpp +1 -1
- package/src/duckdb/src/planner/binder/statement/bind_extension.cpp +1 -1
- package/src/duckdb/src/planner/binder/statement/bind_insert.cpp +4 -4
- package/src/duckdb/src/planner/binder/statement/bind_set.cpp +2 -2
- package/src/duckdb/src/planner/binder/statement/bind_update.cpp +2 -1
- package/src/duckdb/src/planner/binder/statement/bind_vacuum.cpp +2 -2
- package/src/duckdb/src/planner/binder/tableref/bind_basetableref.cpp +4 -3
- package/src/duckdb/src/planner/binder/tableref/bind_pivot.cpp +303 -78
- package/src/duckdb/src/planner/binder/tableref/bind_subqueryref.cpp +4 -4
- package/src/duckdb/src/planner/binder/tableref/bind_table_function.cpp +10 -10
- package/src/duckdb/src/planner/binder/tableref/plan_joinref.cpp +6 -6
- package/src/duckdb/src/planner/binder/tableref/plan_pivotref.cpp +13 -0
- package/src/duckdb/src/planner/binder.cpp +52 -48
- package/src/duckdb/src/planner/expression/bound_aggregate_expression.cpp +8 -8
- package/src/duckdb/src/planner/expression/bound_between_expression.cpp +5 -5
- package/src/duckdb/src/planner/expression/bound_case_expression.cpp +1 -1
- package/src/duckdb/src/planner/expression/bound_cast_expression.cpp +5 -5
- package/src/duckdb/src/planner/expression/bound_columnref_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_comparison_expression.cpp +3 -4
- package/src/duckdb/src/planner/expression/bound_conjunction_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_constant_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_function_expression.cpp +4 -4
- package/src/duckdb/src/planner/expression/bound_lambda_expression.cpp +4 -4
- package/src/duckdb/src/planner/expression/bound_lambdaref_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_operator_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_parameter_expression.cpp +3 -3
- package/src/duckdb/src/planner/expression/bound_reference_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_unnest_expression.cpp +2 -2
- package/src/duckdb/src/planner/expression/bound_window_expression.cpp +16 -16
- package/src/duckdb/src/planner/expression_binder/alter_binder.cpp +1 -1
- package/src/duckdb/src/planner/expression_binder/base_select_binder.cpp +3 -3
- package/src/duckdb/src/planner/expression_binder/check_binder.cpp +1 -1
- package/src/duckdb/src/planner/expression_binder/constant_binder.cpp +11 -1
- package/src/duckdb/src/planner/expression_binder/group_binder.cpp +2 -2
- package/src/duckdb/src/planner/expression_binder/index_binder.cpp +1 -1
- package/src/duckdb/src/planner/expression_binder/lateral_binder.cpp +3 -3
- package/src/duckdb/src/planner/expression_binder/order_binder.cpp +3 -3
- package/src/duckdb/src/planner/expression_binder/qualify_binder.cpp +2 -1
- package/src/duckdb/src/planner/expression_binder/table_function_binder.cpp +7 -3
- package/src/duckdb/src/planner/expression_binder.cpp +24 -32
- package/src/duckdb/src/planner/expression_iterator.cpp +17 -17
- package/src/duckdb/src/planner/joinside.cpp +2 -2
- package/src/duckdb/src/planner/logical_operator.cpp +3 -0
- package/src/duckdb/src/planner/logical_operator_visitor.cpp +26 -26
- package/src/duckdb/src/planner/operator/logical_distinct.cpp +3 -1
- package/src/duckdb/src/planner/operator/logical_filter.cpp +1 -1
- package/src/duckdb/src/planner/operator/logical_join.cpp +1 -1
- package/src/duckdb/src/planner/operator/logical_pivot.cpp +35 -0
- package/src/duckdb/src/planner/operator/logical_recursive_cte.cpp +1 -1
- package/src/duckdb/src/planner/pragma_handler.cpp +2 -2
- package/src/duckdb/src/planner/subquery/flatten_dependent_join.cpp +25 -23
- package/src/duckdb/src/planner/subquery/rewrite_correlated_expressions.cpp +2 -2
- package/src/duckdb/src/planner/table_binding.cpp +8 -8
- package/src/duckdb/src/storage/checkpoint/table_data_writer.cpp +1 -1
- package/src/duckdb/src/storage/data_table.cpp +2 -1
- package/src/duckdb/src/storage/index.cpp +4 -5
- package/src/duckdb/src/storage/local_storage.cpp +2 -1
- package/src/duckdb/src/storage/table/row_group_collection.cpp +1 -1
- package/src/duckdb/src/storage/write_ahead_log.cpp +42 -42
- package/src/duckdb/src/transaction/commit_state.cpp +35 -35
- package/src/duckdb/src/transaction/duck_transaction.cpp +1 -1
- package/src/duckdb/src/transaction/rollback_state.cpp +1 -1
- package/src/duckdb/src/verification/deserialized_statement_verifier.cpp +1 -1
- package/src/duckdb/third_party/libpg_query/include/parser/gram.hpp +773 -793
- package/src/duckdb/third_party/libpg_query/include/parser/kwlist.hpp +1 -11
- package/src/duckdb/third_party/libpg_query/src_backend_parser_gram.cpp +17408 -17751
- package/src/duckdb/ub_extension_icu_third_party_icu_i18n.cpp +5 -5
- package/src/duckdb/ub_src_execution_operator_projection.cpp +2 -0
- package/src/duckdb/ub_src_execution_physical_plan.cpp +2 -0
- package/src/duckdb/ub_src_planner_binder_tableref.cpp +2 -0
- package/src/duckdb/ub_src_planner_operator.cpp +2 -0
package/src/duckdb/src/include/duckdb/execution/operator/join/physical_piecewise_merge_join.hpp
CHANGED
@@ -18,6 +18,9 @@ class MergeJoinGlobalState;
|
|
18
18
|
//! PhysicalPiecewiseMergeJoin represents a piecewise merge loop join between
|
19
19
|
//! two tables
|
20
20
|
class PhysicalPiecewiseMergeJoin : public PhysicalRangeJoin {
|
21
|
+
public:
|
22
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::PIECEWISE_MERGE_JOIN;
|
23
|
+
|
21
24
|
public:
|
22
25
|
PhysicalPiecewiseMergeJoin(LogicalOperator &op, unique_ptr<PhysicalOperator> left,
|
23
26
|
unique_ptr<PhysicalOperator> right, vector<JoinCondition> cond, JoinType join_type,
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalPositionalJoin represents a cross product between two tables
|
17
17
|
class PhysicalPositionalJoin : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::POSITIONAL_JOIN;
|
20
|
+
|
18
21
|
public:
|
19
22
|
PhysicalPositionalJoin(vector<LogicalType> types, unique_ptr<PhysicalOperator> left,
|
20
23
|
unique_ptr<PhysicalOperator> right, idx_t estimated_cardinality);
|
@@ -19,6 +19,9 @@ class OrderGlobalSinkState;
|
|
19
19
|
|
20
20
|
//! Physically re-orders the input data
|
21
21
|
class PhysicalOrder : public PhysicalOperator {
|
22
|
+
public:
|
23
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::ORDER_BY;
|
24
|
+
|
22
25
|
public:
|
23
26
|
PhysicalOrder(vector<LogicalType> types, vector<BoundOrderByNode> orders, vector<idx_t> projections,
|
24
27
|
idx_t estimated_cardinality);
|
@@ -17,6 +17,9 @@ namespace duckdb {
|
|
17
17
|
//! Represents a physical ordering of the data. Note that this will not change
|
18
18
|
//! the data but only add a selection vector.
|
19
19
|
class PhysicalTopN : public PhysicalOperator {
|
20
|
+
public:
|
21
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::TOP_N;
|
22
|
+
|
20
23
|
public:
|
21
24
|
PhysicalTopN(vector<LogicalType> types, vector<BoundOrderByNode> orders, idx_t limit, idx_t offset,
|
22
25
|
idx_t estimated_cardinality);
|
package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_batch_insert.hpp
CHANGED
@@ -13,6 +13,9 @@
|
|
13
13
|
namespace duckdb {
|
14
14
|
|
15
15
|
class PhysicalBatchInsert : public PhysicalOperator {
|
16
|
+
public:
|
17
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::BATCH_INSERT;
|
18
|
+
|
16
19
|
public:
|
17
20
|
//! INSERT INTO
|
18
21
|
PhysicalBatchInsert(vector<LogicalType> types, TableCatalogEntry *table,
|
package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_copy_to_file.hpp
CHANGED
@@ -16,6 +16,9 @@ namespace duckdb {
|
|
16
16
|
|
17
17
|
//! Copy the contents of a query into a table
|
18
18
|
class PhysicalCopyToFile : public PhysicalOperator {
|
19
|
+
public:
|
20
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::COPY_TO_FILE;
|
21
|
+
|
19
22
|
public:
|
20
23
|
PhysicalCopyToFile(vector<LogicalType> types, CopyFunction function, unique_ptr<FunctionData> bind_data,
|
21
24
|
idx_t estimated_cardinality);
|
@@ -15,6 +15,9 @@ class DataTable;
|
|
15
15
|
|
16
16
|
//! Physically delete data from a table
|
17
17
|
class PhysicalDelete : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::DELETE_OPERATOR;
|
20
|
+
|
18
21
|
public:
|
19
22
|
PhysicalDelete(vector<LogicalType> types, TableCatalogEntry &tableref, DataTable &table, idx_t row_id_index,
|
20
23
|
idx_t estimated_cardinality, bool return_chunk)
|
@@ -18,6 +18,9 @@
|
|
18
18
|
namespace duckdb {
|
19
19
|
//! Parse a file from disk using a specified copy function and return the set of chunks retrieved from the file
|
20
20
|
class PhysicalExport : public PhysicalOperator {
|
21
|
+
public:
|
22
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::EXPORT;
|
23
|
+
|
21
24
|
public:
|
22
25
|
PhysicalExport(vector<LogicalType> types, CopyFunction function, unique_ptr<CopyInfo> info,
|
23
26
|
idx_t estimated_cardinality, BoundExportData exported_tables)
|
@@ -20,6 +20,9 @@ class InsertLocalState;
|
|
20
20
|
|
21
21
|
//! Physically insert a set of data into a table
|
22
22
|
class PhysicalInsert : public PhysicalOperator {
|
23
|
+
public:
|
24
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::INSERT;
|
25
|
+
|
23
26
|
public:
|
24
27
|
//! INSERT INTO
|
25
28
|
PhysicalInsert(vector<LogicalType> types, TableCatalogEntry *table, physical_index_vector_t<idx_t> column_index_map,
|
@@ -16,6 +16,9 @@ class DataTable;
|
|
16
16
|
|
17
17
|
//! Physically update data in a table
|
18
18
|
class PhysicalUpdate : public PhysicalOperator {
|
19
|
+
public:
|
20
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::UPDATE;
|
21
|
+
|
19
22
|
public:
|
20
23
|
PhysicalUpdate(vector<LogicalType> types, TableCatalogEntry &tableref, DataTable &table,
|
21
24
|
vector<PhysicalIndex> columns, vector<unique_ptr<Expression>> expressions,
|
@@ -0,0 +1,38 @@
|
|
1
|
+
//===----------------------------------------------------------------------===//
|
2
|
+
// DuckDB
|
3
|
+
//
|
4
|
+
// duckdb/execution/operator/projection/physical_pivot.hpp
|
5
|
+
//
|
6
|
+
//
|
7
|
+
//===----------------------------------------------------------------------===//
|
8
|
+
|
9
|
+
#pragma once
|
10
|
+
|
11
|
+
#include "duckdb/execution/physical_operator.hpp"
|
12
|
+
#include "duckdb/planner/expression.hpp"
|
13
|
+
#include "duckdb/common/string_map_set.hpp"
|
14
|
+
#include "duckdb/planner/tableref/bound_pivotref.hpp"
|
15
|
+
|
16
|
+
namespace duckdb {
|
17
|
+
|
18
|
+
//! PhysicalPivot implements the physical PIVOT operation
|
19
|
+
class PhysicalPivot : public PhysicalOperator {
|
20
|
+
public:
|
21
|
+
PhysicalPivot(vector<LogicalType> types, unique_ptr<PhysicalOperator> child, BoundPivotInfo bound_pivot);
|
22
|
+
|
23
|
+
BoundPivotInfo bound_pivot;
|
24
|
+
//! The map for pivot value -> column index
|
25
|
+
string_map_t<idx_t> pivot_map;
|
26
|
+
//! The empty aggregate values
|
27
|
+
vector<Value> empty_aggregates;
|
28
|
+
|
29
|
+
public:
|
30
|
+
OperatorResultType Execute(ExecutionContext &context, DataChunk &input, DataChunk &chunk,
|
31
|
+
GlobalOperatorState &gstate, OperatorState &state) const override;
|
32
|
+
|
33
|
+
bool ParallelOperator() const override {
|
34
|
+
return true;
|
35
|
+
}
|
36
|
+
};
|
37
|
+
|
38
|
+
} // namespace duckdb
|
@@ -14,6 +14,9 @@
|
|
14
14
|
namespace duckdb {
|
15
15
|
|
16
16
|
class PhysicalProjection : public PhysicalOperator {
|
17
|
+
public:
|
18
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::PROJECTION;
|
19
|
+
|
17
20
|
public:
|
18
21
|
PhysicalProjection(vector<LogicalType> types, vector<unique_ptr<Expression>> select_list,
|
19
22
|
idx_t estimated_cardinality);
|
package/src/duckdb/src/include/duckdb/execution/operator/projection/physical_tableinout_function.hpp
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
//===----------------------------------------------------------------------===//
|
2
2
|
// DuckDB
|
3
3
|
//
|
4
|
-
// duckdb/execution/operator/projection/
|
4
|
+
// duckdb/execution/operator/projection/physical_tableinout_function.hpp
|
5
5
|
//
|
6
6
|
//
|
7
7
|
//===----------------------------------------------------------------------===//
|
@@ -14,8 +14,10 @@
|
|
14
14
|
|
15
15
|
namespace duckdb {
|
16
16
|
|
17
|
-
//! PhysicalWindow implements window functions
|
18
17
|
class PhysicalTableInOutFunction : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::INOUT_FUNCTION;
|
20
|
+
|
19
21
|
public:
|
20
22
|
PhysicalTableInOutFunction(vector<LogicalType> types, TableFunction function_p,
|
21
23
|
unique_ptr<FunctionData> bind_data_p, vector<column_t> column_ids_p,
|
@@ -8,7 +8,6 @@
|
|
8
8
|
|
9
9
|
#pragma once
|
10
10
|
|
11
|
-
#include "duckdb/common/types/chunk_collection.hpp"
|
12
11
|
#include "duckdb/execution/physical_operator.hpp"
|
13
12
|
#include "duckdb/planner/expression.hpp"
|
14
13
|
|
@@ -16,6 +15,9 @@ namespace duckdb {
|
|
16
15
|
|
17
16
|
//! PhysicalUnnest implements the physical UNNEST operation
|
18
17
|
class PhysicalUnnest : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::UNNEST;
|
20
|
+
|
19
21
|
public:
|
20
22
|
PhysicalUnnest(vector<LogicalType> types, vector<unique_ptr<Expression>> select_list, idx_t estimated_cardinality,
|
21
23
|
PhysicalOperatorType type = PhysicalOperatorType::UNNEST);
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! The PhysicalColumnDataScan scans a ColumnDataCollection
|
17
17
|
class PhysicalColumnDataScan : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::COLUMN_DATA_SCAN;
|
20
|
+
|
18
21
|
public:
|
19
22
|
PhysicalColumnDataScan(vector<LogicalType> types, PhysicalOperatorType op_type, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(op_type, std::move(types), estimated_cardinality), collection(nullptr) {
|
@@ -13,6 +13,9 @@
|
|
13
13
|
namespace duckdb {
|
14
14
|
|
15
15
|
class PhysicalDummyScan : public PhysicalOperator {
|
16
|
+
public:
|
17
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::DUMMY_SCAN;
|
18
|
+
|
16
19
|
public:
|
17
20
|
explicit PhysicalDummyScan(vector<LogicalType> types, idx_t estimated_cardinality)
|
18
21
|
: PhysicalOperator(PhysicalOperatorType::DUMMY_SCAN, std::move(types), estimated_cardinality) {
|
@@ -13,6 +13,9 @@
|
|
13
13
|
namespace duckdb {
|
14
14
|
|
15
15
|
class PhysicalEmptyResult : public PhysicalOperator {
|
16
|
+
public:
|
17
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::EMPTY_RESULT;
|
18
|
+
|
16
19
|
public:
|
17
20
|
explicit PhysicalEmptyResult(vector<LogicalType> types, idx_t estimated_cardinality)
|
18
21
|
: PhysicalOperator(PhysicalOperatorType::EMPTY_RESULT, std::move(types), estimated_cardinality) {
|
@@ -16,6 +16,9 @@ namespace duckdb {
|
|
16
16
|
|
17
17
|
//! The PhysicalExpressionScan scans a set of expressions
|
18
18
|
class PhysicalExpressionScan : public PhysicalOperator {
|
19
|
+
public:
|
20
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::EXPRESSION_SCAN;
|
21
|
+
|
19
22
|
public:
|
20
23
|
PhysicalExpressionScan(vector<LogicalType> types, vector<vector<unique_ptr<Expression>>> expressions,
|
21
24
|
idx_t estimated_cardinality)
|
@@ -17,6 +17,9 @@ namespace duckdb {
|
|
17
17
|
|
18
18
|
//! Represents a scan of a base table
|
19
19
|
class PhysicalPositionalScan : public PhysicalOperator {
|
20
|
+
public:
|
21
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::POSITIONAL_SCAN;
|
22
|
+
|
20
23
|
public:
|
21
24
|
//! Regular Table Scan
|
22
25
|
PhysicalPositionalScan(vector<LogicalType> types, unique_ptr<PhysicalOperator> left,
|
@@ -17,6 +17,9 @@ namespace duckdb {
|
|
17
17
|
|
18
18
|
//! Represents a scan of a base table
|
19
19
|
class PhysicalTableScan : public PhysicalOperator {
|
20
|
+
public:
|
21
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::TABLE_SCAN;
|
22
|
+
|
20
23
|
public:
|
21
24
|
//! Regular Table Scan
|
22
25
|
PhysicalTableScan(vector<LogicalType> types, TableFunction function, unique_ptr<FunctionData> bind_data,
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalAlter represents an ALTER TABLE command
|
17
17
|
class PhysicalAlter : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::ALTER;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalAlter(unique_ptr<AlterInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::ALTER, {LogicalType::BOOLEAN}, estimated_cardinality),
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalLoad represents an extension LOAD operation
|
17
17
|
class PhysicalAttach : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::ATTACH;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalAttach(unique_ptr<AttachInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::ATTACH, {LogicalType::BOOLEAN}, estimated_cardinality),
|
package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_function.hpp
CHANGED
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalCreateFunction represents a CREATE FUNCTION command
|
17
17
|
class PhysicalCreateFunction : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_MACRO;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalCreateFunction(unique_ptr<CreateMacroInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::CREATE_MACRO, {LogicalType::BIGINT}, estimated_cardinality),
|
@@ -21,6 +21,9 @@ class DuckTableEntry;
|
|
21
21
|
|
22
22
|
//! Physical CREATE (UNIQUE) INDEX statement
|
23
23
|
class PhysicalCreateIndex : public PhysicalOperator {
|
24
|
+
public:
|
25
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_INDEX;
|
26
|
+
|
24
27
|
public:
|
25
28
|
PhysicalCreateIndex(LogicalOperator &op, TableCatalogEntry &table, const vector<column_t> &column_ids,
|
26
29
|
unique_ptr<CreateIndexInfo> info, vector<unique_ptr<Expression>> unbound_expressions,
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalCreateSchema represents a CREATE SCHEMA command
|
17
17
|
class PhysicalCreateSchema : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_SCHEMA;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalCreateSchema(unique_ptr<CreateSchemaInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::CREATE_SCHEMA, {LogicalType::BIGINT}, estimated_cardinality),
|
package/src/duckdb/src/include/duckdb/execution/operator/schema/physical_create_sequence.hpp
CHANGED
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalCreateSequence represents a CREATE SEQUENCE command
|
17
17
|
class PhysicalCreateSequence : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_SEQUENCE;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalCreateSequence(unique_ptr<CreateSequenceInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::CREATE_SEQUENCE, {LogicalType::BIGINT}, estimated_cardinality),
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! Physically CREATE TABLE statement
|
17
17
|
class PhysicalCreateTable : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_TABLE;
|
20
|
+
|
18
21
|
public:
|
19
22
|
PhysicalCreateTable(LogicalOperator &op, SchemaCatalogEntry *schema, unique_ptr<BoundCreateTableInfo> info,
|
20
23
|
idx_t estimated_cardinality);
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalCreateType represents a CREATE TYPE command
|
17
17
|
class PhysicalCreateType : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_TYPE;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalCreateType(unique_ptr<CreateTypeInfo> info, idx_t estimated_cardinality);
|
20
23
|
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalCreateView represents a CREATE VIEW command
|
17
17
|
class PhysicalCreateView : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::CREATE_VIEW;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalCreateView(unique_ptr<CreateViewInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::CREATE_VIEW, {LogicalType::BIGINT}, estimated_cardinality),
|
@@ -14,6 +14,9 @@
|
|
14
14
|
namespace duckdb {
|
15
15
|
|
16
16
|
class PhysicalDetach : public PhysicalOperator {
|
17
|
+
public:
|
18
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::DETACH;
|
19
|
+
|
17
20
|
public:
|
18
21
|
explicit PhysicalDetach(unique_ptr<DetachInfo> info, idx_t estimated_cardinality)
|
19
22
|
: PhysicalOperator(PhysicalOperatorType::DETACH, {LogicalType::BOOLEAN}, estimated_cardinality),
|
@@ -15,6 +15,9 @@ namespace duckdb {
|
|
15
15
|
|
16
16
|
//! PhysicalDrop represents a DROP [...] command
|
17
17
|
class PhysicalDrop : public PhysicalOperator {
|
18
|
+
public:
|
19
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::DROP;
|
20
|
+
|
18
21
|
public:
|
19
22
|
explicit PhysicalDrop(unique_ptr<DropInfo> info, idx_t estimated_cardinality)
|
20
23
|
: PhysicalOperator(PhysicalOperatorType::DROP, {LogicalType::BOOLEAN}, estimated_cardinality),
|
@@ -16,6 +16,9 @@ namespace duckdb {
|
|
16
16
|
class RecursiveCTEState;
|
17
17
|
|
18
18
|
class PhysicalRecursiveCTE : public PhysicalOperator {
|
19
|
+
public:
|
20
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::RECURSIVE_CTE;
|
21
|
+
|
19
22
|
public:
|
20
23
|
PhysicalRecursiveCTE(vector<LogicalType> types, bool union_all, unique_ptr<PhysicalOperator> top,
|
21
24
|
unique_ptr<PhysicalOperator> bottom, idx_t estimated_cardinality);
|
@@ -11,7 +11,11 @@
|
|
11
11
|
#include "duckdb/execution/physical_operator.hpp"
|
12
12
|
|
13
13
|
namespace duckdb {
|
14
|
+
|
14
15
|
class PhysicalUnion : public PhysicalOperator {
|
16
|
+
public:
|
17
|
+
static constexpr const PhysicalOperatorType TYPE = PhysicalOperatorType::UNION;
|
18
|
+
|
15
19
|
public:
|
16
20
|
PhysicalUnion(vector<LogicalType> types, unique_ptr<PhysicalOperator> top, unique_ptr<PhysicalOperator> bottom,
|
17
21
|
idx_t estimated_cardinality);
|
@@ -15,6 +15,7 @@
|
|
15
15
|
#include "duckdb/common/types/data_chunk.hpp"
|
16
16
|
#include "duckdb/execution/execution_context.hpp"
|
17
17
|
#include "duckdb/optimizer/join_order/join_node.hpp"
|
18
|
+
#include "duckdb/execution/physical_operator_states.hpp"
|
18
19
|
|
19
20
|
namespace duckdb {
|
20
21
|
class Event;
|
@@ -24,63 +25,6 @@ class Pipeline;
|
|
24
25
|
class PipelineBuildState;
|
25
26
|
class MetaPipeline;
|
26
27
|
|
27
|
-
// LCOV_EXCL_START
|
28
|
-
class OperatorState {
|
29
|
-
public:
|
30
|
-
virtual ~OperatorState() {
|
31
|
-
}
|
32
|
-
|
33
|
-
virtual void Finalize(PhysicalOperator *op, ExecutionContext &context) {
|
34
|
-
}
|
35
|
-
};
|
36
|
-
|
37
|
-
class GlobalOperatorState {
|
38
|
-
public:
|
39
|
-
virtual ~GlobalOperatorState() {
|
40
|
-
}
|
41
|
-
};
|
42
|
-
|
43
|
-
class GlobalSinkState {
|
44
|
-
public:
|
45
|
-
GlobalSinkState() : state(SinkFinalizeType::READY) {
|
46
|
-
}
|
47
|
-
virtual ~GlobalSinkState() {
|
48
|
-
}
|
49
|
-
|
50
|
-
SinkFinalizeType state;
|
51
|
-
};
|
52
|
-
|
53
|
-
class LocalSinkState {
|
54
|
-
public:
|
55
|
-
virtual ~LocalSinkState() {
|
56
|
-
}
|
57
|
-
|
58
|
-
//! The current batch index
|
59
|
-
//! This is only set in case RequiresBatchIndex() is true, and the source has support for it (SupportsBatchIndex())
|
60
|
-
//! Otherwise this is left on INVALID_INDEX
|
61
|
-
//! The batch index is a globally unique, increasing index that should be used to maintain insertion order
|
62
|
-
//! //! in conjunction with parallelism
|
63
|
-
idx_t batch_index = DConstants::INVALID_INDEX;
|
64
|
-
};
|
65
|
-
|
66
|
-
class GlobalSourceState {
|
67
|
-
public:
|
68
|
-
virtual ~GlobalSourceState() {
|
69
|
-
}
|
70
|
-
|
71
|
-
virtual idx_t MaxThreads() {
|
72
|
-
return 1;
|
73
|
-
}
|
74
|
-
};
|
75
|
-
|
76
|
-
class LocalSourceState {
|
77
|
-
public:
|
78
|
-
virtual ~LocalSourceState() {
|
79
|
-
}
|
80
|
-
};
|
81
|
-
|
82
|
-
// LCOV_EXCL_STOP
|
83
|
-
|
84
28
|
//! PhysicalOperator is the base class of the physical operators present in the
|
85
29
|
//! execution plan
|
86
30
|
class PhysicalOperator {
|
@@ -224,6 +168,23 @@ public:
|
|
224
168
|
virtual bool AllOperatorsPreserveOrder() const;
|
225
169
|
|
226
170
|
virtual void BuildPipelines(Pipeline ¤t, MetaPipeline &meta_pipeline);
|
171
|
+
|
172
|
+
public:
|
173
|
+
template <class TARGET>
|
174
|
+
TARGET &Cast() {
|
175
|
+
if (TARGET::TYPE != PhysicalOperatorType::INVALID && type != TARGET::TYPE) {
|
176
|
+
throw InternalException("Failed to cast physical operator to type - physical operator type mismatch");
|
177
|
+
}
|
178
|
+
return (TARGET &)*this;
|
179
|
+
}
|
180
|
+
|
181
|
+
template <class TARGET>
|
182
|
+
const TARGET &Cast() const {
|
183
|
+
if (TARGET::TYPE != PhysicalOperatorType::INVALID && type != TARGET::TYPE) {
|
184
|
+
throw InternalException("Failed to cast physical operator to type - physical operator type mismatch");
|
185
|
+
}
|
186
|
+
return (const TARGET &)*this;
|
187
|
+
}
|
227
188
|
};
|
228
189
|
|
229
190
|
//! Contains state for the CachingPhysicalOperator
|
@@ -0,0 +1,150 @@
|
|
1
|
+
//===----------------------------------------------------------------------===//
|
2
|
+
// DuckDB
|
3
|
+
//
|
4
|
+
// duckdb/execution/physical_operator_states.hpp
|
5
|
+
//
|
6
|
+
//
|
7
|
+
//===----------------------------------------------------------------------===//
|
8
|
+
|
9
|
+
#pragma once
|
10
|
+
|
11
|
+
#include "duckdb/catalog/catalog.hpp"
|
12
|
+
#include "duckdb/common/common.hpp"
|
13
|
+
#include "duckdb/common/enums/operator_result_type.hpp"
|
14
|
+
#include "duckdb/common/enums/physical_operator_type.hpp"
|
15
|
+
#include "duckdb/common/types/data_chunk.hpp"
|
16
|
+
#include "duckdb/execution/execution_context.hpp"
|
17
|
+
#include "duckdb/optimizer/join_order/join_node.hpp"
|
18
|
+
|
19
|
+
namespace duckdb {
|
20
|
+
class Event;
|
21
|
+
class Executor;
|
22
|
+
class PhysicalOperator;
|
23
|
+
class Pipeline;
|
24
|
+
class PipelineBuildState;
|
25
|
+
class MetaPipeline;
|
26
|
+
|
27
|
+
// LCOV_EXCL_START
|
28
|
+
class OperatorState {
|
29
|
+
public:
|
30
|
+
virtual ~OperatorState() {
|
31
|
+
}
|
32
|
+
|
33
|
+
virtual void Finalize(PhysicalOperator *op, ExecutionContext &context) {
|
34
|
+
}
|
35
|
+
|
36
|
+
template <class TARGET>
|
37
|
+
TARGET &Cast() {
|
38
|
+
D_ASSERT(dynamic_cast<TARGET *>(this));
|
39
|
+
return (TARGET &)*this;
|
40
|
+
}
|
41
|
+
template <class TARGET>
|
42
|
+
const TARGET &Cast() const {
|
43
|
+
D_ASSERT(dynamic_cast<const TARGET *>(this));
|
44
|
+
return (const TARGET &)*this;
|
45
|
+
}
|
46
|
+
};
|
47
|
+
|
48
|
+
class GlobalOperatorState {
|
49
|
+
public:
|
50
|
+
virtual ~GlobalOperatorState() {
|
51
|
+
}
|
52
|
+
|
53
|
+
template <class TARGET>
|
54
|
+
TARGET &Cast() {
|
55
|
+
D_ASSERT(dynamic_cast<TARGET *>(this));
|
56
|
+
return (TARGET &)*this;
|
57
|
+
}
|
58
|
+
template <class TARGET>
|
59
|
+
const TARGET &Cast() const {
|
60
|
+
D_ASSERT(dynamic_cast<const TARGET *>(this));
|
61
|
+
return (const TARGET &)*this;
|
62
|
+
}
|
63
|
+
};
|
64
|
+
|
65
|
+
class GlobalSinkState {
|
66
|
+
public:
|
67
|
+
GlobalSinkState() : state(SinkFinalizeType::READY) {
|
68
|
+
}
|
69
|
+
virtual ~GlobalSinkState() {
|
70
|
+
}
|
71
|
+
|
72
|
+
SinkFinalizeType state;
|
73
|
+
|
74
|
+
template <class TARGET>
|
75
|
+
TARGET &Cast() {
|
76
|
+
D_ASSERT(dynamic_cast<TARGET *>(this));
|
77
|
+
return (TARGET &)*this;
|
78
|
+
}
|
79
|
+
template <class TARGET>
|
80
|
+
const TARGET &Cast() const {
|
81
|
+
D_ASSERT(dynamic_cast<const TARGET *>(this));
|
82
|
+
return (const TARGET &)*this;
|
83
|
+
}
|
84
|
+
};
|
85
|
+
|
86
|
+
class LocalSinkState {
|
87
|
+
public:
|
88
|
+
virtual ~LocalSinkState() {
|
89
|
+
}
|
90
|
+
|
91
|
+
//! The current batch index
|
92
|
+
//! This is only set in case RequiresBatchIndex() is true, and the source has support for it (SupportsBatchIndex())
|
93
|
+
//! Otherwise this is left on INVALID_INDEX
|
94
|
+
//! The batch index is a globally unique, increasing index that should be used to maintain insertion order
|
95
|
+
//! //! in conjunction with parallelism
|
96
|
+
idx_t batch_index = DConstants::INVALID_INDEX;
|
97
|
+
|
98
|
+
template <class TARGET>
|
99
|
+
TARGET &Cast() {
|
100
|
+
D_ASSERT(dynamic_cast<TARGET *>(this));
|
101
|
+
return (TARGET &)*this;
|
102
|
+
}
|
103
|
+
template <class TARGET>
|
104
|
+
const TARGET &Cast() const {
|
105
|
+
D_ASSERT(dynamic_cast<const TARGET *>(this));
|
106
|
+
return (const TARGET &)*this;
|
107
|
+
}
|
108
|
+
};
|
109
|
+
|
110
|
+
class GlobalSourceState {
|
111
|
+
public:
|
112
|
+
virtual ~GlobalSourceState() {
|
113
|
+
}
|
114
|
+
|
115
|
+
virtual idx_t MaxThreads() {
|
116
|
+
return 1;
|
117
|
+
}
|
118
|
+
|
119
|
+
template <class TARGET>
|
120
|
+
TARGET &Cast() {
|
121
|
+
D_ASSERT(dynamic_cast<TARGET *>(this));
|
122
|
+
return (TARGET &)*this;
|
123
|
+
}
|
124
|
+
template <class TARGET>
|
125
|
+
const TARGET &Cast() const {
|
126
|
+
D_ASSERT(dynamic_cast<const TARGET *>(this));
|
127
|
+
return (const TARGET &)*this;
|
128
|
+
}
|
129
|
+
};
|
130
|
+
|
131
|
+
class LocalSourceState {
|
132
|
+
public:
|
133
|
+
virtual ~LocalSourceState() {
|
134
|
+
}
|
135
|
+
|
136
|
+
template <class TARGET>
|
137
|
+
TARGET &Cast() {
|
138
|
+
D_ASSERT(dynamic_cast<TARGET *>(this));
|
139
|
+
return (TARGET &)*this;
|
140
|
+
}
|
141
|
+
template <class TARGET>
|
142
|
+
const TARGET &Cast() const {
|
143
|
+
D_ASSERT(dynamic_cast<const TARGET *>(this));
|
144
|
+
return (const TARGET &)*this;
|
145
|
+
}
|
146
|
+
};
|
147
|
+
|
148
|
+
// LCOV_EXCL_STOP
|
149
|
+
|
150
|
+
} // namespace duckdb
|