날짜 데이터 타입입니다. 0000-01-01부터 9999-12-31까지의 날짜 범위를 지원합니다. 값은 Unix epoch 이후의 일 수를 나타내며, 네이티브 바이트 순서의 부호 있는 32비트 정수로 저장됩니다. 0은 1970-01-01을 나타내고, 음수 값은 1970-01-01 이전의 일 수를 나타냅니다.
예시
Date32 타입 컬럼이 있는 테이블을 생성하고 데이터를 삽입합니다:
CREATE TABLE dt32
(
`timestamp` Date32,
`event_id` UInt8
)
ENGINE = TinyLog;-- Parse Date
-- - from string,
-- - from 'small' integer interpreted as number of days since 1970-01-01, and
-- - from 'big' integer interpreted as number of seconds since 1970-01-01.
INSERT INTO dt32 VALUES ('2100-01-01', 1), (47482, 2), (4102444800, 3);
SELECT * FROM dt32;┌──timestamp─┬─event_id─┐
│ 2100-01-01 │ 1 │
│ 2100-01-01 │ 2 │
│ 2100-01-01 │ 3 │
└────────────┴──────────┘관련 항목