Skip to content

Unix Timestamp (microseconds)

Type Registry

Unix Timestamp (microseconds)

datetime.epoch.unix_microseconds

Microseconds since epoch. Used in high-frequency trading, distributed tracing (Jaeger, Zipkin), and InfluxDB.

Domain datetimeepoch
Casts to TIMESTAMP
Scope Universal

Try it

CLI
$ finetype infer -i "1705312200000000"
→ datetime.epoch.unix_microseconds

DuckDB

Detect
SELECT finetype('1705312200000000');
-- → 'datetime.epoch.unix_microseconds'
Cast expression
to_timestamp({col}::BIGINT / 1000000)
Safe cast pipeline
-- Normalise and cast in one step
SELECT TRY_CAST(finetype_cast(my_column) AS TIMESTAMP) AS clean_value
FROM my_table
WHERE finetype(my_column) = 'datetime.epoch.unix_microseconds';

JSON Schema

finetype schema datetime.epoch.unix_microseconds
{
  "$id": "https://noon.sh/schemas/datetime.epoch.unix_microseconds",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "Microseconds since epoch. Used in high-frequency trading, distributed tracing (Jaeger, Zipkin), and InfluxDB.",
  "examples": [
    "1705312200000000",
    "1577836799999999"
  ],
  "maxLength": 16,
  "minLength": 16,
  "pattern": "^\\d{16}$",
  "title": "Unix Timestamp (microseconds)",
  "type": "string"
}

Examples

17053122000000001577836799999999

Types in datetime