-
Notifications
You must be signed in to change notification settings - Fork 8.3k
system.parts inconsistent quoting #4735
Copy link
Copy link
Closed
Labels
bugConfirmed user-visible misbehaviour in official releaseConfirmed user-visible misbehaviour in official release
Description
18.16 address quoting problems in system.parts. See #3109 and #3652.
After that change all the single values partition names are unquoted always (also for Strings / DateTimes etc), and it is inconsistent, so for example - you can't just create alters from system.parts in a simple manner because String / Date / DateTime - based partitions are also unquoted.
Check that:
SELECT 'ALTER TABLE ' || table || ' DETACH PARTITION ' || partition from system.parts group by table, partition ORDER BY table, partition;
ALTER TABLE toyyyymm_partitioning DETACH PARTITION 201802 -- ok
ALTER TABLE empty_partitioning DETACH PARTITION tuple() -- ok
ALTER TABLE tuple_partitioing DETACH PARTITION (3,3,'333') -- ok
ALTER TABLE float_part DETACH PARTITION 0.001 -- ok
ALTER TABLE int_part DETACH PARTITION 0 -- ok
ALTER TABLE date_partitioning DETACH PARTITION 2018-05-16 -- wrong, quotes needed
ALTER TABLE string_partitioning DETACH PARTITION string_partition_id -- wrong, quotes needed
ALTER TABLE datetime_partitioning DETACH PARTITION 2019-03-20 14:12:59 -- wrong, quotes neededReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugConfirmed user-visible misbehaviour in official releaseConfirmed user-visible misbehaviour in official release