aboutsummaryrefslogtreecommitdiffstats
path: root/yql/essentials/tests/sql/suites/join/cbo_4tables.sql
blob: b96f5c3a79a2e5fdc187415edbccf53c914e9bee (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
USE plato;

pragma CostBasedOptimizer="native";
pragma yt.MapJoinLimit="1000";
pragma yt.LookupJoinLimit="1000";
pragma yt.LookupJoinMaxRows="100";
pragma yt.ExtendedStatsMaxChunkCount="0";
pragma yt.JoinMergeTablesLimit="100";

SELECT
    InputA.Key1, InputA.Key2, InputA.Value, InputB.val, InputC.v, InputD.value as vald
FROM
    InputA
    INNER JOIN InputD ON InputA.Key2 = InputD.k
    INNER JOIN InputB ON InputA.Fk1 = InputB.k
    INNER JOIN InputC ON InputA.Key1 = InputC.k