mirror of
https://github.com/hanzo-ds/sqlparser.git
synced 2026-10-30 20:53:50 +00:00
20 lines
1.0 KiB
SQL
20 lines
1.0 KiB
SQL
-- Origin SQL:
|
|
OPTIMIZE TABLE table DEDUPLICATE; -- all columns
|
|
OPTIMIZE TABLE table DEDUPLICATE BY *; -- excludes MATERIALIZED and ALIAS columns
|
|
OPTIMIZE TABLE table DEDUPLICATE BY colX,colY,colZ;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY * EXCEPT colX;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY * EXCEPT (colX, colY);
|
|
OPTIMIZE TABLE table DEDUPLICATE BY COLUMNS('column-matched-by-regex');
|
|
OPTIMIZE TABLE table DEDUPLICATE BY COLUMNS('column-matched-by-regex') EXCEPT colX;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY COLUMNS('column-matched-by-regex') EXCEPT (colX, colY);
|
|
|
|
-- Format SQL:
|
|
OPTIMIZE TABLE table DEDUPLICATE;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY *;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY colX, colY, colZ;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY * EXCEPT colX;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY * EXCEPT (colX, colY);
|
|
OPTIMIZE TABLE table DEDUPLICATE BY COLUMNS('column-matched-by-regex');
|
|
OPTIMIZE TABLE table DEDUPLICATE BY COLUMNS('column-matched-by-regex') EXCEPT colX;
|
|
OPTIMIZE TABLE table DEDUPLICATE BY COLUMNS('column-matched-by-regex') EXCEPT (colX, colY);
|