internal-packages/clickhouse/README.md
The following document is heavily inspired by the Unkey ClickHouse naming conventions.
This document outlines the naming conventions for tables and materialized views in our ClickHouse setup. Adhering to these conventions ensures consistency, clarity, and ease of management across our data infrastructure.
Format: [prefix]_[domain]_[description]_[version]
raw_: Input data tablestmp_{yourname}_: Temporary tables for experiments, add your name, so it's easy to identify ownership._v1, _v2, etc.For aggregated or summary tables, use suffixes like:
_per_day_per_month_summaryFormat: [description]_[aggregation]_mv_[version]
mv_[version]Raw Data Table:
raw_sales_transactions_v1
Materialized View:
active_users_per_day_mv_v2
Temporary Table:
tmp_eric_user_analysis_v1
Aggregated Table:
sales_summary_per_hour_mv_v1
Maintain consistent naming across related tables, views, and other objects:
raw_user_activity_v1user_activity_per_day_v1user_activity_per_day_mv_v1By following these conventions, we ensure a clear, consistent, and scalable naming structure for our ClickHouse setup.