Hacker News new | ask | show | jobs
by hodgesrm 1481 days ago
Actually that table syntax partitions by month, which is a little non-intuitve. In modern ClickHouse SQL it would look like the following.

  CREATE TABLE tsbs_modern (
    created_date    Date     DEFAULT today(),
    created_at      DateTime DEFAULT now(),
    time            String,
    tags_id         UInt32,
    additional_tags String   DEFAULT ''
  ) ENGINE = MergeTree
  PARTITION BY toYYYYMM(created_date)
  ORDER BY (tags_id, created_at)
2 comments

While the partitioning is okay, the order by is still problematic. See https://telegra.ph/No-QuestDB-is-not-Faster-than-ClickHouse-...
That article was a good response.
Thanks, you're right. Mea culpa
But your point that it's out of date is definitely right.