MeridianMERIDIAN

RFC 2822

Email header datetime format. Used in SMTP, HTTP headers, and RSS feeds. Includes abbreviated weekday and month names.

RFC 2822

datetime.timestamp.rfc_2822

Email header datetime format. Used in SMTP, HTTP headers, and RSS feeds. Includes abbreviated weekday and month names.

Domain
datetime
Category
timestamp
Casts to
TIMESTAMPTZ
Scope
Universal

Try it

CLI
$ finetype infer -i "Tue, 15 Jan 2024 10:30:00 GMT+00:00" --mode column
→ datetime.timestamp.rfc_2822

DuckDB

Detect
SELECT ft_infer('Tue, 15 Jan 2024 10:30:00 GMT+00:00');
-- → 'datetime.timestamp.rfc_2822'
Cast expression
strptime({col}, '%a, %d %b %Y %H:%M:%S %z')
-- Format: %a, %d %b %Y %H:%M:%S %z
Safe cast pipeline
-- Normalise and cast in one step
SELECT TRY_CAST(ft_cast(my_column) AS TIMESTAMPTZ) AS clean_value
FROM my_table
WHERE ft_infer(my_column) = 'datetime.timestamp.rfc_2822';

JSON Schema

finetype taxonomy datetime.timestamp.rfc_2822 -o json-schema
{
  "$id": "https://meridian.online/schemas/datetime.timestamp.rfc_2822",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "Email header datetime format. Used in SMTP, HTTP headers, and RSS feeds. Includes abbreviated weekday and month names.",
  "examples": [
    "Tue, 15 Jan 2024 10: 30: 00 GMT+00: 00",
    "Sun, 31 Dec 2023 23: 59: 59 GMT+00: 00"
  ],
  "pattern": "^[A-Z][a-z]{2}, \\d{2} [A-Z][a-z]{2} \\d{4} \\d{2}:\\d{2}:\\d{2} .+$",
  "title": "RFC 2822",
  "type": "string",
  "x-finetype-label": "datetime.timestamp.rfc_2822",
  "x-finetype-pii": false
}

Examples

Tue, 15 Jan 2024 10:30:00 GMT+00:00Sun, 31 Dec 2023 23:59:59 GMT+00:00

Type Registry