Implementation:ClickHouse ClickHouse Base Types
Appearance
| Knowledge Sources | |
|---|---|
| Domains | Data_Types, Core |
| Last Updated | 2026-02-08 00:00 GMT |
Overview
Fundamental type aliases used throughout ClickHouse.
Description
Defines Int8/UInt8/Int16/UInt16/Int32/UInt32/Int64/UInt64/Float32/Float64/String aliases with specific semantics (UInt8=char8_t, Int8=_BitInt(8)).
Usage
Use as the standard numeric types throughout ClickHouse codebase for consistency.
Code Reference
Source Location
- Repository: ClickHouse
- File: base/base/types.h
- Lines: 1-38
Signature
using UInt8 = char8_t;
using Int8 = signed _BitInt(8);
using UInt16 = uint16_t;
using UInt32 = uint32_t;
using UInt64 = uint64_t;
using Int16 = int16_t;
using Int32 = int32_t;
using Int64 = int64_t;
using Float32 = float;
using Float64 = double;
using String = std::string;
Import
#include <base/types.h>
Usage Examples
#include <base/types.h>
// Use standard ClickHouse types
UInt64 user_id = 123456;
Int32 temperature = -5;
Float64 price = 19.99;
String name = "Alice";
// These are the fundamental types used throughout ClickHouse
UInt8 byte = 0xFF;
Int8 signed_byte = -128;
Related Pages
Page Connections
Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment