Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
ClickHouse launches Claude-powered Agents and House Mates partner program at Open House 2026 Read more →
了解如何在 ClickHouse 中使用自定义路径结构,将按年和月分区的数据写入 S3 存储桶。
CREATE TABLE sample_data ( `name` String, `age` Int, `time` DateTime ) ENGINE = MergeTree ORDER BY name
INSERT INTO sample_data SELECT * FROM generateRandom( 'name String, age Int, time DateTime', 10, 10, 10 ) LIMIT 10000;
my_bucket
INSERT INTO FUNCTION s3( 'https://s3-host:4321/my_bucket/{_partition_id}/file.parquet.gz', 's3-access-key', 's3-secret-access-key', Parquet, 'name String, age Int, time DateTime' ) PARTITION BY concat( formatDateTime(time, '%Y'), '/', formatDateTime(time, '%m') ) SELECT name, age, time FROM sample_data Query id: 55adcf22-f6af-491e-b697-d09694bbcc56 Ok. 0 rows in set. Elapsed: 15.579 sec. Processed 10.00 thousand rows, 219.93 KB (641.87 rows/s., 14.12 KB/s.)
此页面对您有帮助吗?