@@ -2796,24 +2796,11 @@ Y_UNIT_TEST_SUITE(KqpIndexes) {
27962796
27972797 auto & stats = NYdb::TProtoAccessor::GetProto (*result.GetStats ());
27982798
2799- if (serverSettings.AppConfig .GetTableServiceConfig ().GetEnableKqpDataQueryStreamLookup ()) {
2800- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access ().size (), 2 );
2801- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).name (), " /Root/TestTable" );
2802- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).reads ().rows (), 3 );
2803- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).name (), " /Root/TestTable/ix_cust/indexImplTable" );
2804- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).reads ().rows (), 3 );
2805- } else {
2806- int indexPhaseId = 0 ;
2807- int tablePhaseId = 1 ;
2808-
2809- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (tablePhaseId).table_access ().size (), 1 );
2810- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (tablePhaseId).table_access (0 ).name (), " /Root/TestTable" );
2811- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (tablePhaseId).table_access (0 ).reads ().rows (), 3 );
2812-
2813- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (indexPhaseId).table_access ().size (), 1 );
2814- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (indexPhaseId).table_access (0 ).name (), " /Root/TestTable/ix_cust/indexImplTable" );
2815- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (indexPhaseId).table_access (0 ).reads ().rows (), 3 );
2816- }
2799+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access ().size (), 2 );
2800+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).name (), " /Root/TestTable" );
2801+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).reads ().rows (), 3 );
2802+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).name (), " /Root/TestTable/ix_cust/indexImplTable" );
2803+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).reads ().rows (), 3 );
28172804 }
28182805 }
28192806
@@ -2844,24 +2831,11 @@ Y_UNIT_TEST_SUITE(KqpIndexes) {
28442831
28452832 auto & stats = NYdb::TProtoAccessor::GetProto (*result.GetStats ());
28462833
2847- if (serverSettings.AppConfig .GetTableServiceConfig ().GetEnableKqpDataQueryStreamLookup ()) {
2848- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access ().size (), 2 );
2849- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).name (), " /Root/TestTable" );
2850- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).reads ().rows (), 2 );
2851- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).name (), " /Root/TestTable/ix_cust2/indexImplTable" );
2852- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).reads ().rows (), 2 );
2853- } else {
2854- int indexPhaseId = 0 ;
2855- int tablePhaseId = 1 ;
2856-
2857- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (tablePhaseId).table_access ().size (), 1 );
2858- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (tablePhaseId).table_access (0 ).name (), " /Root/TestTable" );
2859- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (tablePhaseId).table_access (0 ).reads ().rows (), 2 );
2860-
2861- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (indexPhaseId).table_access ().size (), 1 );
2862- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (indexPhaseId).table_access (0 ).name (), " /Root/TestTable/ix_cust2/indexImplTable" );
2863- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (indexPhaseId).table_access (0 ).reads ().rows (), 2 );
2864- }
2834+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access ().size (), 2 );
2835+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).name (), " /Root/TestTable" );
2836+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).reads ().rows (), 2 );
2837+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).name (), " /Root/TestTable/ix_cust2/indexImplTable" );
2838+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).reads ().rows (), 2 );
28652839 }
28662840 }
28672841
@@ -4855,7 +4829,6 @@ R"([[#;#;["Primary1"];[41u]];[["Secondary2"];[2u];["Primary2"];[42u]];[["Seconda
48554829 .SetKqpSettings ({setting});
48564830
48574831 NKikimrConfig::TAppConfig appConfig;
4858- appConfig.MutableTableServiceConfig ()->SetEnableKqpDataQueryStreamLookup (true );
48594832 appConfig.MutableTableServiceConfig ()->SetEnableKqpDataQueryStreamIdxLookupJoin (true );
48604833 // setting channel buffer size so small to make sure that we will be able to transfer at least
48614834 // one row in stream lookup.
@@ -4998,30 +4971,13 @@ R"([[#;#;["Primary1"];[41u]];[["Secondary2"];[2u];["Primary2"];[42u]];[["Seconda
49984971
49994972 auto & stats = NYdb::TProtoAccessor::GetProto (*result2.GetStats ());
50004973
5001- int readPhase = 0 ;
5002- if (serverSettings.AppConfig .GetTableServiceConfig ().GetEnableKqpDataQueryStreamLookup ()) {
5003- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases ().size (), 1 );
5004-
5005- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access ().size (), 2 );
5006- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (0 ).name (), " /Root/SecondaryComplexKeys" );
5007- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (0 ).reads ().rows (), 1 );
5008- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (1 ).name (), " /Root/SecondaryComplexKeys/Index/indexImplTable" );
5009- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (1 ).reads ().rows (), 1 );
5010- } else {
5011- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases ().size (), 3 );
5012-
5013- readPhase++;
5014-
5015- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access ().size (), 1 );
5016- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (0 ).name (), " /Root/SecondaryComplexKeys/Index/indexImplTable" );
5017- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (0 ).reads ().rows (), 1 );
5018-
5019- readPhase++;
4974+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases ().size (), 1 );
50204975
5021- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access ().size (), 1 );
5022- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (0 ).name (), " /Root/SecondaryComplexKeys" );
5023- UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (readPhase).table_access (0 ).reads ().rows (), 1 );
5024- }
4976+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access ().size (), 2 );
4977+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).name (), " /Root/SecondaryComplexKeys" );
4978+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (0 ).reads ().rows (), 1 );
4979+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).name (), " /Root/SecondaryComplexKeys/Index/indexImplTable" );
4980+ UNIT_ASSERT_VALUES_EQUAL (stats.query_phases (0 ).table_access (1 ).reads ().rows (), 1 );
50254981 }
50264982 }
50274983
0 commit comments