Skip to main content
Field types define write formats and read results. Select types under Schema when creating a table. The primary key id uses a permitted string type and cannot be changed arbitrarily to a numeric field.

Strings and chain identifiers

Python types below describe common BlockDB SDK read representations. SQL types describe analytics-storage mappings; use the actual query result’s type information for a specific column. Use consistent lowercase addresses and hexadecimal identifiers. HASH has a different length from transaction and block hashes and is not interchangeable with them.

Numbers and booleans

Large-integer precision

UINT256 reads return decimal strings. Convert to Python integers before computation:
Write integers outside the signed 64-bit range as decimal strings, for example:
Do not convert to float before writing an integer back, as that may lose precision. Similarly, do not pass large integers through JavaScript Number. UINT256 uses VARBINARY in SQL, while the query results page displays decimal strings. The display format does not determine the SQL type. For exact calculations, convert the values you read to Python int.

Dates and timestamps

Time Table interfaces accept strings and Python datetime values. Times without a timezone are treated as UTC. Prefer timezone-aware inputs to avoid confusing display timezone with data time. BlockDB’s block_timestamp field is an RFC3339 string, while timestamp in a Leafage block dictionary is Unix seconds. The similar names use different formats.

Structured fields

After choosing LIST or DICT in the field editor, select the element or key/value types. Nested values must satisfy their own type requirements. In SQL, use JSON functions to parse these fields. Older data or metadata may also contain names such as OBJECT, DATASET, BIGINT, DOUBLE, or DECIMAL. These are not new-field types in the current selector. Follow the Schema when reading existing tables, and use the types above for new tables. Missing values are usually Python None or JSON null, distinct from an empty string, 0, or False. Primary keys cannot be null. Time Table batch writes require non-null id, time_at, and value fields.