Skip to content

Commit

Permalink
Update local-timestamp example (#2735)
Browse files Browse the repository at this point in the history
The concept of the local-timestamp is each value is a recording of what can be seen on a calendar and a clock hanging on the wall, for example, "1969-07-20 16:17:39". It can be decomposed into year, month, day, hour, minute, and seconds fields, but with no time zone information available, it does not correspond to any specific point in time. It is often used in legacy systems.

The example was 12 hours off.
  • Loading branch information
Fokko committed Feb 13, 2024
1 parent 705f87c commit 9db06a3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/content/en/docs/++version++/Specification/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -888,7 +888,7 @@ The `local-timestamp-{millis,micros,nanos}` logical type represents a timestamp
- `local-timestamp-micros`: logical type annotates an Avro `long`, where the long stores the number of microseconds, from 1 January 1970 00:00:00.000000.
- `local-timestamp-nanos`: logical type annotates an Avro `long`, where the long stores the number of nanoseconds, from 1 January 1970 00:00:00.000000000.

Example: Given an event at noon local time (12:00) on January 1, 2000, in Helsinki where the local time was two hours east of UTC (UTC+2). The timestamp is converted to Avro long 946684800000 (milliseconds) and then written.
Example: Given an event at noon local time (12:00) on January 1, 2000, in Helsinki where the local time was two hours east of UTC (UTC+2). The timestamp is converted to Avro long 946728000000 (milliseconds) and then written.

### Duration
The `duration` logical type represents an amount of time defined by a number of months, days and milliseconds. This is not equivalent to a number of milliseconds, because, depending on the moment in time from which the duration is measured, the number of days in the month and number of milliseconds in a day may differ. Other standard periods such as years, quarters, hours and minutes can be expressed through these basic periods.
Expand Down

0 comments on commit 9db06a3

Please sign in to comment.