diff --git a/ydb/library/yql/dq/opt/dq_opt_log.cpp b/ydb/library/yql/dq/opt/dq_opt_log.cpp index 467fec490c9a..c8969a768f06 100644 --- a/ydb/library/yql/dq/opt/dq_opt_log.cpp +++ b/ydb/library/yql/dq/opt/dq_opt_log.cpp @@ -182,32 +182,18 @@ static void CollectSinkStages(const NNodes::TDqQuery& dqQuery, THashSet(); - - THashSet sinkStages; - CollectSinkStages(dqQuery, sinkStages); - TOptimizeExprSettings settings{nullptr}; - settings.VisitLambdas = false; - bool deletedDqQueryChild = false; - TExprNode::TPtr newDqQueryNode; - auto status = OptimizeExpr(dqQueryNode.Ptr(), newDqQueryNode, [&sinkStages, &deletedDqQueryChild](const TExprNode::TPtr& node, TExprContext& ctx) -> TExprNode::TPtr { - for (ui32 childIndex = 0; childIndex < node->ChildrenSize(); ++childIndex) { - TExprNode* child = node->Child(childIndex); - if (child->IsCallable(NNodes::TDqQuery::CallableName())) { - NNodes::TDqQuery dqQueryChild(child); - CollectSinkStages(dqQueryChild, sinkStages); - deletedDqQueryChild = true; - return ctx.ChangeChild(*node, childIndex, dqQueryChild.World().Ptr()); - } - } - return node; - }, ctx, settings); - YQL_ENSURE(status != IGraphTransformer::TStatus::Error, "Failed to merge DqQuery nodes: " << status); - - if (deletedDqQueryChild) { - auto dqQueryBuilder = Build(ctx, dqQuery.Pos()); - dqQueryBuilder.World(newDqQueryNode->ChildPtr(TDqQuery::idx_World)); - + auto maybeDqQuery = dqQueryNode.Maybe(); + YQL_ENSURE(maybeDqQuery, "Expected DqQuery!"); + auto dqQuery = maybeDqQuery.Cast(); + + if (auto maybeDqQueryChild = dqQuery.World().Maybe()) { + auto dqQueryChild = maybeDqQueryChild.Cast(); + auto dqQueryBuilder = Build(ctx, dqQuery.Pos()) + .World(dqQueryChild.World()); + + THashSet sinkStages; + CollectSinkStages(dqQuery, sinkStages); + CollectSinkStages(maybeDqQueryChild.Cast(), sinkStages); auto sinkStagesBuilder = dqQueryBuilder.SinkStages(); for (const TExprNode::TPtr& stage : sinkStages) { sinkStagesBuilder.Add(stage); diff --git a/ydb/library/yql/providers/clickhouse/expr_nodes/yql_clickhouse_expr_nodes.json b/ydb/library/yql/providers/clickhouse/expr_nodes/yql_clickhouse_expr_nodes.json index a3378a39810d..358d2e112b8b 100644 --- a/ydb/library/yql/providers/clickhouse/expr_nodes/yql_clickhouse_expr_nodes.json +++ b/ydb/library/yql/providers/clickhouse/expr_nodes/yql_clickhouse_expr_nodes.json @@ -41,9 +41,10 @@ "Base": "TCallable", "Match": {"Type": "Callable", "Name": "ClSourceSettings"}, "Children": [ - {"Index": 0, "Name": "Table", "Type": "TCoAtom"}, - {"Index": 1, "Name": "Token", "Type": "TCoSecureParam"}, - {"Index": 2, "Name": "Columns", "Type": "TCoAtomList"} + {"Index": 0, "Name": "World", "Type": "TExprBase"}, + {"Index": 1, "Name": "Table", "Type": "TCoAtom"}, + {"Index": 2, "Name": "Token", "Type": "TCoSecureParam"}, + {"Index": 3, "Name": "Columns", "Type": "TCoAtomList"} ] } ] diff --git a/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_datasource_type_ann.cpp b/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_datasource_type_ann.cpp index fd18aa1286d4..7b3caf8cc043 100644 --- a/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_datasource_type_ann.cpp +++ b/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_datasource_type_ann.cpp @@ -25,7 +25,11 @@ class TClickHouseDataSourceTypeAnnotationTransformer : public TVisitorTransforme } TStatus HandleSourceSettings(const TExprNode::TPtr& input, TExprContext& ctx) { - if (!EnsureArgsCount(*input, 3U, ctx)) { + if (!EnsureArgsCount(*input, 4, ctx)) { + return TStatus::Error; + } + + if (!EnsureWorldType(*input->Child(TClSourceSettings::idx_World), ctx)) { return TStatus::Error; } diff --git a/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_dq_integration.cpp b/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_dq_integration.cpp index 0f997f1e4495..f9d370bdacbd 100644 --- a/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_dq_integration.cpp +++ b/ydb/library/yql/providers/clickhouse/provider/yql_clickhouse_dq_integration.cpp @@ -52,6 +52,7 @@ class TClickHouseDqIntegration: public TDqIntegrationBase { return Build(ctx, read->Pos()) .Input() + .World(clReadTable.World()) .Table(clReadTable.Table()) .Token() .Name().Build(token) diff --git a/ydb/library/yql/providers/generic/expr_nodes/yql_generic_expr_nodes.json b/ydb/library/yql/providers/generic/expr_nodes/yql_generic_expr_nodes.json index 88e63d15833d..90652bc3037e 100644 --- a/ydb/library/yql/providers/generic/expr_nodes/yql_generic_expr_nodes.json +++ b/ydb/library/yql/providers/generic/expr_nodes/yql_generic_expr_nodes.json @@ -41,11 +41,12 @@ "Base": "TCallable", "Match": {"Type": "Callable", "Name": "GenSourceSettings"}, "Children": [ - {"Index": 0, "Name": "Cluster", "Type": "TCoAtom"}, - {"Index": 1, "Name": "Table", "Type": "TCoAtom"}, - {"Index": 2, "Name": "Token", "Type": "TCoSecureParam"}, - {"Index": 3, "Name": "Columns", "Type": "TCoAtomList"}, - {"Index": 4, "Name": "FilterPredicate", "Type": "TCoLambda"} + {"Index": 0, "Name": "World", "Type": "TExprBase"}, + {"Index": 1, "Name": "Cluster", "Type": "TCoAtom"}, + {"Index": 2, "Name": "Table", "Type": "TCoAtom"}, + {"Index": 3, "Name": "Token", "Type": "TCoSecureParam"}, + {"Index": 4, "Name": "Columns", "Type": "TCoAtomList"}, + {"Index": 5, "Name": "FilterPredicate", "Type": "TCoLambda"} ] } ] diff --git a/ydb/library/yql/providers/generic/provider/yql_generic_datasource_type_ann.cpp b/ydb/library/yql/providers/generic/provider/yql_generic_datasource_type_ann.cpp index d7606a16c423..9640ef5f94be 100644 --- a/ydb/library/yql/providers/generic/provider/yql_generic_datasource_type_ann.cpp +++ b/ydb/library/yql/providers/generic/provider/yql_generic_datasource_type_ann.cpp @@ -49,7 +49,11 @@ namespace NYql { } TStatus HandleSourceSettings(const TExprNode::TPtr& input, TExprContext& ctx) { - if (!EnsureArgsCount(*input, 5, ctx)) { + if (!EnsureArgsCount(*input, 6, ctx)) { + return TStatus::Error; + } + + if (!EnsureWorldType(*input->Child(TGenSourceSettings::idx_World), ctx)) { return TStatus::Error; } diff --git a/ydb/library/yql/providers/generic/provider/yql_generic_dq_integration.cpp b/ydb/library/yql/providers/generic/provider/yql_generic_dq_integration.cpp index ea093f871458..7bf32674c40e 100644 --- a/ydb/library/yql/providers/generic/provider/yql_generic_dq_integration.cpp +++ b/ydb/library/yql/providers/generic/provider/yql_generic_dq_integration.cpp @@ -85,6 +85,7 @@ namespace NYql { // clang-format off return Build(ctx, read->Pos()) .Input() + .World(genReadTable.World()) .Cluster(genReadTable.DataSource().Cluster()) .Table(genReadTable.Table()) .Token() diff --git a/ydb/library/yql/providers/pq/expr_nodes/yql_pq_expr_nodes.json b/ydb/library/yql/providers/pq/expr_nodes/yql_pq_expr_nodes.json index 0b178695aaeb..d70cc37688f4 100644 --- a/ydb/library/yql/providers/pq/expr_nodes/yql_pq_expr_nodes.json +++ b/ydb/library/yql/providers/pq/expr_nodes/yql_pq_expr_nodes.json @@ -67,11 +67,12 @@ "Base": "TCallable", "Match": {"Type": "Callable", "Name": "DqPqTopicSource"}, "Children": [ - {"Index": 0, "Name": "Topic", "Type": "TPqTopic"}, - {"Index": 1, "Name": "Columns", "Type": "TExprBase"}, - {"Index": 2, "Name": "Settings", "Type": "TCoNameValueTupleList"}, - {"Index": 3, "Name": "Token", "Type": "TCoSecureParam"}, - {"Index": 4, "Name": "FilterPredicate", "Type": "TCoLambda"} + {"Index": 0, "Name": "World", "Type": "TExprBase"}, + {"Index": 1, "Name": "Topic", "Type": "TPqTopic"}, + {"Index": 2, "Name": "Columns", "Type": "TExprBase"}, + {"Index": 3, "Name": "Settings", "Type": "TCoNameValueTupleList"}, + {"Index": 4, "Name": "Token", "Type": "TCoSecureParam"}, + {"Index": 5, "Name": "FilterPredicate", "Type": "TCoLambda"} ] }, { diff --git a/ydb/library/yql/providers/pq/provider/yql_pq_datasource_type_ann.cpp b/ydb/library/yql/providers/pq/provider/yql_pq_datasource_type_ann.cpp index ea93ce37449a..5dff9c61584a 100644 --- a/ydb/library/yql/providers/pq/provider/yql_pq_datasource_type_ann.cpp +++ b/ydb/library/yql/providers/pq/provider/yql_pq_datasource_type_ann.cpp @@ -132,11 +132,16 @@ class TPqDataSourceTypeAnnotationTransformer : public TVisitorTransformerBase { } TStatus HandleDqTopicSource(TExprBase input, TExprContext& ctx) { - if (!EnsureArgsCount(input.Ref(), 5, ctx)) { + if (!EnsureArgsCount(input.Ref(), 6, ctx)) { return TStatus::Error; } TDqPqTopicSource topicSource = input.Cast(); + + if (!EnsureWorldType(topicSource.World().Ref(), ctx)) { + return TStatus::Error; + } + TPqTopic topic = topicSource.Topic(); if (!EnsureCallable(topic.Ref(), ctx)) { diff --git a/ydb/library/yql/providers/pq/provider/yql_pq_dq_integration.cpp b/ydb/library/yql/providers/pq/provider/yql_pq_dq_integration.cpp index 3a305edaf59d..530bda256dc0 100644 --- a/ydb/library/yql/providers/pq/provider/yql_pq_dq_integration.cpp +++ b/ydb/library/yql/providers/pq/provider/yql_pq_dq_integration.cpp @@ -147,6 +147,7 @@ class TPqDqIntegration: public TDqIntegrationBase { return Build(ctx, read->Pos()) .Input() + .World(pqReadTopic.World()) .Topic(pqReadTopic.Topic()) .Columns(std::move(columnNames)) .Settings(BuildTopicReadSettings(clusterName, dqSettings, read->Pos(), format, ctx)) diff --git a/ydb/library/yql/providers/s3/expr_nodes/yql_s3_expr_nodes.json b/ydb/library/yql/providers/s3/expr_nodes/yql_s3_expr_nodes.json index 631e07dd3912..f7121ceaf650 100644 --- a/ydb/library/yql/providers/s3/expr_nodes/yql_s3_expr_nodes.json +++ b/ydb/library/yql/providers/s3/expr_nodes/yql_s3_expr_nodes.json @@ -45,10 +45,11 @@ "Base": "TCallable", "Match": {"Type": "CallableBase"}, "Children": [ - {"Index": 0, "Name": "Paths", "Type": "TS3Paths"}, - {"Index": 1, "Name": "Token", "Type": "TCoSecureParam"}, - {"Index": 2, "Name": "RowsLimitHint", "Type": "TCoAtom"}, - {"Index": 3, "Name": "Path", "Type": "TCoAtom"} + {"Index": 0, "Name": "World", "Type": "TExprBase"}, + {"Index": 1, "Name": "Paths", "Type": "TS3Paths"}, + {"Index": 2, "Name": "Token", "Type": "TCoSecureParam"}, + {"Index": 3, "Name": "RowsLimitHint", "Type": "TCoAtom"}, + {"Index": 4, "Name": "Path", "Type": "TCoAtom"} ] }, { @@ -56,9 +57,9 @@ "Base": "TS3SourceSettingsBase", "Match": {"Type": "Callable", "Name": "S3SourceSettings"}, "Children": [ - {"Index": 4, "Name": "SizeLimit", "Type": "TExprBase", "Optional": true}, - {"Index": 5, "Name": "PathPattern", "Type": "TExprBase", "Optional": true}, - {"Index": 6, "Name": "PathPatternVariant", "Type": "TExprBase", "Optional": true} + {"Index": 5, "Name": "SizeLimit", "Type": "TExprBase", "Optional": true}, + {"Index": 6, "Name": "PathPattern", "Type": "TExprBase", "Optional": true}, + {"Index": 7, "Name": "PathPatternVariant", "Type": "TExprBase", "Optional": true} ] }, { @@ -66,10 +67,10 @@ "Base": "TS3SourceSettingsBase", "Match": {"Type": "Callable", "Name": "S3ParseSettings"}, "Children": [ - {"Index": 4, "Name": "Format", "Type": "TCoAtom"}, - {"Index": 5, "Name": "RowType", "Type": "TExprBase"}, - {"Index": 6, "Name": "FilterPredicate", "Type": "TCoLambda"}, - {"Index": 7, "Name": "Settings", "Type": "TExprBase", "Optional": true} + {"Index": 5, "Name": "Format", "Type": "TCoAtom"}, + {"Index": 6, "Name": "RowType", "Type": "TExprBase"}, + {"Index": 7, "Name": "FilterPredicate", "Type": "TCoLambda"}, + {"Index": 8, "Name": "Settings", "Type": "TExprBase", "Optional": true} ] }, { diff --git a/ydb/library/yql/providers/s3/provider/yql_s3_datasource_type_ann.cpp b/ydb/library/yql/providers/s3/provider/yql_s3_datasource_type_ann.cpp index 6c9be1472d0d..35fdeadde733 100644 --- a/ydb/library/yql/providers/s3/provider/yql_s3_datasource_type_ann.cpp +++ b/ydb/library/yql/providers/s3/provider/yql_s3_datasource_type_ann.cpp @@ -303,7 +303,11 @@ class TS3DataSourceTypeAnnotationTransformer : public TVisitorTransformerBase { } TStatus HandleS3SourceSettings(const TExprNode::TPtr& input, TExprContext& ctx) { - if (!EnsureMinArgsCount(*input, 4U, ctx)) { + if (!EnsureMinMaxArgsCount(*input, 5, 8, ctx)) { + return TStatus::Error; + } + + if (!EnsureWorldType(*input->Child(TS3SourceSettings::idx_World), ctx)) { return TStatus::Error; } @@ -335,7 +339,11 @@ class TS3DataSourceTypeAnnotationTransformer : public TVisitorTransformerBase { } TStatus HandleS3ParseSettings(const TExprNode::TPtr& input, TExprContext& ctx) { - if (!EnsureMinMaxArgsCount(*input, 7U, 8U, ctx)) { + if (!EnsureMinMaxArgsCount(*input, 8, 9, ctx)) { + return TStatus::Error; + } + + if (!EnsureWorldType(*input->Child(TS3ParseSettings::idx_World), ctx)) { return TStatus::Error; } diff --git a/ydb/library/yql/providers/s3/provider/yql_s3_dq_integration.cpp b/ydb/library/yql/providers/s3/provider/yql_s3_dq_integration.cpp index d377e84ae8ca..9ab184da57b1 100644 --- a/ydb/library/yql/providers/s3/provider/yql_s3_dq_integration.cpp +++ b/ydb/library/yql/providers/s3/provider/yql_s3_dq_integration.cpp @@ -286,6 +286,7 @@ class TS3DqIntegration: public TDqIntegrationBase { if (const auto useCoro = State_->Configuration->SourceCoroActor.Get(); (!useCoro || *useCoro) && format != "raw" && format != "json_list") { return Build(ctx, read->Pos()) .Input() + .World(s3ReadObject.World()) .Paths(s3ReadObject.Object().Paths()) .Token() .Name().Build(token) @@ -331,6 +332,7 @@ class TS3DqIntegration: public TDqIntegrationBase { auto emptyNode = Build(ctx, read->Pos()).Done().Ptr(); return Build(ctx, read->Pos()) .Input() + .World(s3ReadObject.World()) .Paths(s3ReadObject.Object().Paths()) .Token() .Name().Build(token) diff --git a/ydb/library/yql/providers/solomon/expr_nodes/yql_solomon_expr_nodes.json b/ydb/library/yql/providers/solomon/expr_nodes/yql_solomon_expr_nodes.json index 05798f70cbbd..fe28e1d7acc6 100644 --- a/ydb/library/yql/providers/solomon/expr_nodes/yql_solomon_expr_nodes.json +++ b/ydb/library/yql/providers/solomon/expr_nodes/yql_solomon_expr_nodes.json @@ -48,18 +48,19 @@ "Base": "TCallable", "Match": {"Type": "Callable", "Name": "SoSourceSettings"}, "Children": [ - {"Index": 0, "Name": "Project", "Type": "TCoAtom"}, - {"Index": 1, "Name": "Token", "Type": "TCoSecureParam"}, - {"Index": 2, "Name": "RowType", "Type": "TExprBase"}, - {"Index": 3, "Name": "SystemColumns", "Type": "TCoAtomList"}, - {"Index": 4, "Name": "LabelNames", "Type": "TCoAtomList"}, - {"Index": 5, "Name": "From", "Type": "TCoAtom"}, - {"Index": 6, "Name": "To", "Type": "TCoAtom"}, - {"Index": 7, "Name": "Program", "Type": "TCoAtom"}, - {"Index": 8, "Name": "DownsamplingDisabled", "Type": "TCoBool"}, - {"Index": 9, "Name": "DownsamplingAggregation", "Type": "TCoAtom"}, - {"Index": 10, "Name": "DownsamplingFill", "Type": "TCoAtom"}, - {"Index": 11, "Name": "DownsamplingGridSec", "Type": "TCoUint32"} + {"Index": 0, "Name": "World", "Type": "TExprBase"}, + {"Index": 1, "Name": "Project", "Type": "TCoAtom"}, + {"Index": 2, "Name": "Token", "Type": "TCoSecureParam"}, + {"Index": 3, "Name": "RowType", "Type": "TExprBase"}, + {"Index": 4, "Name": "SystemColumns", "Type": "TCoAtomList"}, + {"Index": 5, "Name": "LabelNames", "Type": "TCoAtomList"}, + {"Index": 6, "Name": "From", "Type": "TCoAtom"}, + {"Index": 7, "Name": "To", "Type": "TCoAtom"}, + {"Index": 8, "Name": "Program", "Type": "TCoAtom"}, + {"Index": 9, "Name": "DownsamplingDisabled", "Type": "TCoBool"}, + {"Index": 10, "Name": "DownsamplingAggregation", "Type": "TCoAtom"}, + {"Index": 11, "Name": "DownsamplingFill", "Type": "TCoAtom"}, + {"Index": 12, "Name": "DownsamplingGridSec", "Type": "TCoUint32"} ] }, { diff --git a/ydb/library/yql/providers/solomon/provider/yql_solomon_datasource_type_ann.cpp b/ydb/library/yql/providers/solomon/provider/yql_solomon_datasource_type_ann.cpp index adbaf60e944e..e1f2fe94e95d 100644 --- a/ydb/library/yql/providers/solomon/provider/yql_solomon_datasource_type_ann.cpp +++ b/ydb/library/yql/providers/solomon/provider/yql_solomon_datasource_type_ann.cpp @@ -34,7 +34,11 @@ class TSolomonDataSourceTypeAnnotationTransformer : public TVisitorTransformerBa } TStatus HandleSoSourceSettings(const TExprNode::TPtr& input, TExprContext& ctx) { - if (!EnsureArgsCount(*input, 12U, ctx)) { + if (!EnsureArgsCount(*input, 13, ctx)) { + return TStatus::Error; + } + + if (!EnsureWorldType(*input->Child(TSoSourceSettings::idx_World), ctx)) { return TStatus::Error; } diff --git a/ydb/library/yql/providers/solomon/provider/yql_solomon_dq_integration.cpp b/ydb/library/yql/providers/solomon/provider/yql_solomon_dq_integration.cpp index b675a22a91c6..a6a8eb14a8ba 100644 --- a/ydb/library/yql/providers/solomon/provider/yql_solomon_dq_integration.cpp +++ b/ydb/library/yql/providers/solomon/provider/yql_solomon_dq_integration.cpp @@ -211,6 +211,7 @@ class TSolomonDqIntegration: public TDqIntegrationBase { return Build(ctx, read->Pos()) .Input() + .World(soReadObject.World()) .Project(soReadObject.Object().Project()) .Token() .Name().Build(token) diff --git a/ydb/library/yql/providers/ydb/expr_nodes/yql_ydb_expr_nodes.json b/ydb/library/yql/providers/ydb/expr_nodes/yql_ydb_expr_nodes.json index 534f097ec39d..62557c87f9a8 100644 --- a/ydb/library/yql/providers/ydb/expr_nodes/yql_ydb_expr_nodes.json +++ b/ydb/library/yql/providers/ydb/expr_nodes/yql_ydb_expr_nodes.json @@ -30,9 +30,10 @@ "Base": "TCallable", "Match": {"Type": "Callable", "Name": "YdbSourceSettings"}, "Children": [ - {"Index": 0, "Name": "Table", "Type": "TCoAtom"}, - {"Index": 1, "Name": "Token", "Type": "TCoSecureParam"}, - {"Index": 2, "Name": "Columns", "Type": "TCoAtomList"} + {"Index": 0, "Name": "World", "Type": "TExprBase"}, + {"Index": 1, "Name": "Table", "Type": "TCoAtom"}, + {"Index": 2, "Name": "Token", "Type": "TCoSecureParam"}, + {"Index": 3, "Name": "Columns", "Type": "TCoAtomList"} ] }, { diff --git a/ydb/library/yql/providers/ydb/provider/yql_ydb_datasource_type_ann.cpp b/ydb/library/yql/providers/ydb/provider/yql_ydb_datasource_type_ann.cpp index edbc95c25e07..c03b2a3191e5 100644 --- a/ydb/library/yql/providers/ydb/provider/yql_ydb_datasource_type_ann.cpp +++ b/ydb/library/yql/providers/ydb/provider/yql_ydb_datasource_type_ann.cpp @@ -29,7 +29,11 @@ class TYdbDataSourceTypeAnnotationTransformer : public TVisitorTransformerBase { TStatus HandleYdbSourceSettings(const TExprNode::TPtr& input, TExprNode::TPtr& output, TExprContext& ctx) { Y_UNUSED(output); - if (!EnsureArgsCount(*input, 3U, ctx)) { + if (!EnsureArgsCount(*input, 4, ctx)) { + return TStatus::Error; + } + + if (!EnsureWorldType(*input->Child(TYdbSourceSettings::idx_World), ctx)) { return TStatus::Error; } diff --git a/ydb/library/yql/providers/ydb/provider/yql_ydb_dq_integration.cpp b/ydb/library/yql/providers/ydb/provider/yql_ydb_dq_integration.cpp index 7ff7fc1c5cc7..9f165f0ba32c 100644 --- a/ydb/library/yql/providers/ydb/provider/yql_ydb_dq_integration.cpp +++ b/ydb/library/yql/providers/ydb/provider/yql_ydb_dq_integration.cpp @@ -101,6 +101,7 @@ class TYdbDqIntegration: public TDqIntegrationBase { return Build(ctx, read->Pos()) .Input() + .World(ydbReadTable.World()) .Table(ydbReadTable.Table()) .Token() .Name().Build(token) diff --git a/ydb/library/yql/tests/sql/dq_file/part7/canondata/test.test_match_recognize-without_order_by--Results_/extracted b/ydb/library/yql/tests/sql/dq_file/part7/canondata/test.test_match_recognize-without_order_by--Results_/extracted deleted file mode 100644 index abd564f4a8c8..000000000000 --- a/ydb/library/yql/tests/sql/dq_file/part7/canondata/test.test_match_recognize-without_order_by--Results_/extracted +++ /dev/null @@ -1,5 +0,0 @@ -/program.sql:
: Fatal: Optimization - - /program.sql:
:8:1: Fatal: ydb/library/yql/core/yql_opt_match_recognize.cpp:xxx ExpandMatchRecognize(): requirement sortOrder->ChildrenSize() == 1 failed, message: Expect ORDER BY timestamp for MATCH_RECOGNIZE - select * from (select * from AS_TABLE($data) MATCH_RECOGNIZE( - ^ \ No newline at end of file diff --git a/ydb/library/yql/tests/sql/hybrid_file/part2/canondata/result.json b/ydb/library/yql/tests/sql/hybrid_file/part2/canondata/result.json index e59e9089a1b0..57260df1270c 100644 --- a/ydb/library/yql/tests/sql/hybrid_file/part2/canondata/result.json +++ b/ydb/library/yql/tests/sql/hybrid_file/part2/canondata/result.json @@ -2871,9 +2871,9 @@ ], "test.test[window-full/session--Debug]": [ { - "checksum": "b06da41f9a9ea38646c43487f4b8b96a", - "size": 13340, - "uri": "https://{canondata_backend}/1775319/8ac8c87858e0db34f5a3c99b3f4ca1084cccbace/resource.tar.gz#test.test_window-full_session--Debug_/opt.yql_patched" + "checksum": "497487e14c39e6f6eeacce4046bfb2f5", + "size": 14172, + "uri": "https://{canondata_backend}/1777230/34342462b74dcf33b334172059f34ab28ba50ba6/resource.tar.gz#test.test_window-full_session--Debug_/opt.yql_patched" } ], "test.test[window-full/session--Plan]": [ @@ -2885,9 +2885,9 @@ ], "test.test[window-full/session_aliases--Debug]": [ { - "checksum": "e021555a47e83d0b792765a8ee82be94", - "size": 14124, - "uri": "https://{canondata_backend}/1775319/8ac8c87858e0db34f5a3c99b3f4ca1084cccbace/resource.tar.gz#test.test_window-full_session_aliases--Debug_/opt.yql_patched" + "checksum": "cf18b79ffda288cb9cf374749f268298", + "size": 14969, + "uri": "https://{canondata_backend}/1777230/34342462b74dcf33b334172059f34ab28ba50ba6/resource.tar.gz#test.test_window-full_session_aliases--Debug_/opt.yql_patched" } ], "test.test[window-full/session_aliases--Plan]": [ diff --git a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Basic-default.txt_/opt.yql b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Basic-default.txt_/opt.yql index 6576fbab7b62..4ba8a34de0a9 100644 --- a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Basic-default.txt_/opt.yql +++ b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Basic-default.txt_/opt.yql @@ -4,9 +4,9 @@ (let $3 (DataType 'String)) (let $4 (StructType '('"kind" $3) '('"labels" (DictType $3 $3)) '('"ts" (DataType 'Datetime)) '('type $3) '('"value" (DataType 'Double)))) (let $5 '('"kind" '"labels" '"value" '"ts" 'type)) -(let $6 (SoSourceSettings '"my_project" (SecureParam '"cluster:default_local_solomon") $4 $5 '() '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"false") '"AVG" '"PREVIOUS" (Uint32 '"15"))) +(let $6 (SoSourceSettings world '"my_project" (SecureParam '"cluster:default_local_solomon") $4 $5 '() '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"false") '"AVG" '"PREVIOUS" (Uint32 '"15"))) (let $7 (DqStage '((DqSource (DataSource '"solomon" '"local_solomon") $6)) (lambda '($10) $10) '('('"_logical_id" '199321)))) -(let $8 (DqStage '((DqCnUnionAll (TDqOutput $7 '"0"))) (lambda '($11) $11) '('('"_logical_id" '199342)))) +(let $8 (DqStage '((DqCnUnionAll (TDqOutput $7 '"0"))) (lambda '($11) $11) '('('"_logical_id" '199348)))) (let $9 (ResPull! $1 $2 (Key) (DqCnResult (TDqOutput $8 '"0") '()) '('('type) '('autoref)) '"dq")) (return (Commit! (Commit! $9 $2) (DataSink '"solomon" '"local_solomon"))) ) diff --git a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Downsampling-default.txt_/opt.yql b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Downsampling-default.txt_/opt.yql index b2bd63ebba1e..f72069cc7f3b 100644 --- a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Downsampling-default.txt_/opt.yql +++ b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-Downsampling-default.txt_/opt.yql @@ -4,9 +4,9 @@ (let $3 (DataType 'String)) (let $4 (StructType '('"kind" $3) '('"labels" (DictType $3 $3)) '('"ts" (DataType 'Datetime)) '('type $3) '('"value" (DataType 'Double)))) (let $5 '('"kind" '"labels" '"value" '"ts" 'type)) -(let $6 (SoSourceSettings '"my_project" (SecureParam '"cluster:default_local_solomon") $4 $5 '() '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"true") '"SUM" '"PREVIOUS" (Uint32 '"25"))) +(let $6 (SoSourceSettings world '"my_project" (SecureParam '"cluster:default_local_solomon") $4 $5 '() '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"true") '"SUM" '"PREVIOUS" (Uint32 '"25"))) (let $7 (DqStage '((DqSource (DataSource '"solomon" '"local_solomon") $6)) (lambda '($10) $10) '('('"_logical_id" '199345)))) -(let $8 (DqStage '((DqCnUnionAll (TDqOutput $7 '"0"))) (lambda '($11) $11) '('('"_logical_id" '199366)))) +(let $8 (DqStage '((DqCnUnionAll (TDqOutput $7 '"0"))) (lambda '($11) $11) '('('"_logical_id" '199372)))) (let $9 (ResPull! $1 $2 (Key) (DqCnResult (TDqOutput $8 '"0") '()) '('('type) '('autoref)) '"dq")) (return (Commit! (Commit! $9 $2) (DataSink '"solomon" '"local_solomon"))) ) diff --git a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-DownsamplingValidSettings-default.txt_/opt.yql b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-DownsamplingValidSettings-default.txt_/opt.yql index 2bd63c06c6fb..a2b215515150 100644 --- a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-DownsamplingValidSettings-default.txt_/opt.yql +++ b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-DownsamplingValidSettings-default.txt_/opt.yql @@ -4,9 +4,9 @@ (let $3 (DataType 'String)) (let $4 (StructType '('"kind" $3) '('"labels" (DictType $3 $3)) '('"ts" (DataType 'Datetime)) '('type $3) '('"value" (DataType 'Double)))) (let $5 '('"kind" '"labels" '"value" '"ts" 'type)) -(let $6 (SoSourceSettings '"my_project" (SecureParam '"cluster:default_local_solomon") $4 $5 '() '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"false") '"SUM" '"PREVIOUS" (Uint32 '"15"))) +(let $6 (SoSourceSettings world '"my_project" (SecureParam '"cluster:default_local_solomon") $4 $5 '() '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"false") '"SUM" '"PREVIOUS" (Uint32 '"15"))) (let $7 (DqStage '((DqSource (DataSource '"solomon" '"local_solomon") $6)) (lambda '($10) $10) '('('"_logical_id" '199333)))) -(let $8 (DqStage '((DqCnUnionAll (TDqOutput $7 '"0"))) (lambda '($11) $11) '('('"_logical_id" '199354)))) +(let $8 (DqStage '((DqCnUnionAll (TDqOutput $7 '"0"))) (lambda '($11) $11) '('('"_logical_id" '199360)))) (let $9 (ResPull! $1 $2 (Key) (DqCnResult (TDqOutput $8 '"0") '()) '('('type) '('autoref)) '"dq")) (return (Commit! (Commit! $9 $2) (DataSink '"solomon" '"local_solomon"))) ) diff --git a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-LabelColumns-default.txt_/opt.yql b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-LabelColumns-default.txt_/opt.yql index 06f24e141131..eeb3bfecb443 100644 --- a/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-LabelColumns-default.txt_/opt.yql +++ b/ydb/library/yql/tests/sql/solomon/canondata/test.test_solomon-LabelColumns-default.txt_/opt.yql @@ -8,9 +8,9 @@ (let $7 (StructType '($3 $4) '($5 $4) '($6 $4) '('"kind" $4) '('"project" $4) '('"ts" (DataType 'Datetime)) '('type $4) '('"value" (DataType 'Double)))) (let $8 '('"kind" '"value" '"ts" 'type)) (let $9 '($3 $5 '"project" $6)) -(let $10 (SoSourceSettings '"my_project" (SecureParam '"cluster:default_local_solomon") $7 $8 $9 '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"false") '"AVG" '"PREVIOUS" (Uint32 '"15"))) +(let $10 (SoSourceSettings world '"my_project" (SecureParam '"cluster:default_local_solomon") $7 $8 $9 '"2023-12-08T14:40:39Z" '"2023-12-08T14:45:39Z" '"{}" (Bool '"false") '"AVG" '"PREVIOUS" (Uint32 '"15"))) (let $11 (DqStage '((DqSource (DataSource '"solomon" '"local_solomon") $10)) (lambda '($14) $14) '('('"_logical_id" '199359)))) -(let $12 (DqStage '((DqCnUnionAll (TDqOutput $11 '"0"))) (lambda '($15) $15) '('('"_logical_id" '199380)))) +(let $12 (DqStage '((DqCnUnionAll (TDqOutput $11 '"0"))) (lambda '($15) $15) '('('"_logical_id" '199386)))) (let $13 (ResPull! $1 $2 (Key) (DqCnResult (TDqOutput $12 '"0") '()) '('('type) '('autoref)) '"dq")) (return (Commit! (Commit! $13 $2) (DataSink '"solomon" '"local_solomon"))) ) diff --git a/ydb/library/yql/tests/sql/yt_native_file/part7/canondata/test.test_match_recognize-without_order_by--Results_/extracted b/ydb/library/yql/tests/sql/yt_native_file/part7/canondata/test.test_match_recognize-without_order_by--Results_/extracted deleted file mode 100644 index abd564f4a8c8..000000000000 --- a/ydb/library/yql/tests/sql/yt_native_file/part7/canondata/test.test_match_recognize-without_order_by--Results_/extracted +++ /dev/null @@ -1,5 +0,0 @@ -/program.sql:
: Fatal: Optimization - - /program.sql:
:8:1: Fatal: ydb/library/yql/core/yql_opt_match_recognize.cpp:xxx ExpandMatchRecognize(): requirement sortOrder->ChildrenSize() == 1 failed, message: Expect ORDER BY timestamp for MATCH_RECOGNIZE - select * from (select * from AS_TABLE($data) MATCH_RECOGNIZE( - ^ \ No newline at end of file