Skip to content

Commit 88de15a

Browse files
committed
backport timestamp doc fix
1 parent 6c14ee6 commit 88de15a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

docs/dates_and_times.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ reasoning behind it, and describe approaches to working with these types.
77
timestamps (Cassandra DateType)
88
-------------------------------
99

10-
Timestamps in Cassandra are timezone-naive timestamps encoded as microseconds since UNIX epoch. Clients working with
10+
Timestamps in Cassandra are timezone-naive timestamps encoded as millseconds since UNIX epoch. Clients working with
1111
timestamps in this database usually find it easiest to reason about them if they are always assumed to be UTC. To quote the
1212
pytz documentation, "The preferred way of dealing with times is to always work in UTC, converting to localtime only when
1313
generating output to be read by humans." The driver adheres to this tenant, and assumes UTC is always in the database. The
@@ -34,7 +34,7 @@ Note the second point above applies even to "local" times created using ``now()`
3434
These do not contain timezone information intrinsically, so they will be assumed to be UTC and not shifted. When generating
3535
timestamps in the application, it is clearer to use ``datetime.utcnow()`` to be explicit about it.
3636

37-
If the input for a timestamp is numeric, it is assumed to be a epoch-relative microsecond timestamp, as specified in the
37+
If the input for a timestamp is numeric, it is assumed to be a epoch-relative millisecond timestamp, as specified in the
3838
CQL spec -- no scaling or conversion is done.
3939

4040
Read Path

0 commit comments

Comments
 (0)