Commit Graph

7 Commits

Author SHA1 Message Date
Azat Khuzhin
8b438bcd3c Change formatting of subqueries (make it more human friendly)
Fix trailing whitespaces in FROM/IN clause with subqueries in multiline
mode, and also changes the output of the queries slightly in a more
human friendly way.

Before:

    $ clickhouse-format <<<'select * from system.one, (select * from system.one)'
    SELECT *
    FROM system.one
    ,
    (
        SELECT *
        FROM system.one
    )

After:

    $ clickhouse-format <<<'select * from system.one, (select * from system.one)'
    SELECT *
    FROM system.one,
    (
        SELECT *
        FROM system.one
    )

v2: Fix subqueries formatting in a different way
v3: Adjust *.reference in tests
v4: Fix modernize-loop-convert in ASTTablesInSelectQuery
2021-05-20 21:04:12 +03:00
Vladimir
9fe20c1628
Revert "Move conditions from JOIN ON to WHERE" 2021-04-07 14:57:20 +03:00
vdimir
3d19d0644e
Update join on associativity in some tests 2021-02-16 13:46:25 +03:00
Azat Khuzhin
0324770773 Remove all trailing whitespaces in tests
sed -r -i \
    -e 's/SELECT $/SELECT/' \
    -e 's/SELECT DISTINCT $/SELECT DISTINCT/' \
    -e 's/WITH $/WITH/' \ # zero matches, new test will be added
    -e 's/ARRAY JOIN $/ARRAY JOIN/' \
    -e 's/GROUP BY $/GROUP BY/' \
    -e 's/ORDER BY $/ORDER BY/' \
    -e 's/LIMIT ([0-9]+) BY $/LIMIT \1 BY/' \ # zero matches, new test will be added
    tests/queries/*/*.sql \
    tests/queries/*/*.reference

(With except for tests/queries/0_stateless/00751_default_databasename_for_view.reference)
2020-09-09 01:36:58 +03:00
Nikolai Kochetov
e1481ccfc2 Add initial explain. 2020-06-27 12:30:38 +03:00
Alexey Milovidov
2a0da608fd Update tests 2020-06-02 02:31:50 +03:00
Ivan
97f2a2213e
Move all folders inside /dbms one level up (#9974)
* Move some code outside dbms/src folder
* Fix paths
2020-04-02 02:51:21 +03:00