Skip to content

Commit 743bbf0

Browse files
reword
1 parent 31ba236 commit 743bbf0

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

modules/ROOT/pages/values-and-types/temporal.adoc

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -511,13 +511,11 @@ For more information, see the xref::values-and-types/temporal.adoc#cypher-tempor
511511
[[cypher-temporal-specify-instant-examples]]
512512
=== Examples
513513

514-
In order to create or parse a temporal instant type, its corresponding xref:functions/temporal/index.adoc[function] must be used.
514+
To work with a particular temporal instant type, its corresponding xref:functions/temporal/index.adoc[function] must be used.
515515
For example, in order to create a property value of type `ZONED DATETIME`, the xref:functions/temporal/index.adoc#functions-datetime[`datetime()`] function must be used.
516516

517-
This section provides examples of how to create properties with different temporal value types and how to parse temporal instant values.
518517
For specific examples, see:
519518

520-
521519
* xref:values-and-types/temporal.adoc#examples-date[`DATE`]
522520
* xref:values-and-types/temporal.adoc#examples-localtime[`LOCAL TIME`]
523521
* xref:values-and-types/temporal.adoc#examples-zonedtime[`ZONED TIME`]
@@ -548,7 +546,7 @@ RETURN n.date AS date, valueType(n.date) AS temporalValueType
548546
549547
| 2025-02-18 | "DATE NOT NULL"
550548
551-
1+d|Rows: 1
549+
2+d|Rows: 1
552550
|===
553551
554552
.Create a `DATE` property value using components
@@ -566,7 +564,7 @@ RETURN n.date AS date, valueType(n.date) AS temporalValueType
566564
567565
| 2025-02-18 | "DATE NOT NULL"
568566
569-
1+d|Rows: 1
567+
2+d|Rows: 1
570568
|===
571569
572570
.Parse a `DATE` using the week date format:
@@ -973,6 +971,8 @@ RETURN d.timezone, d.offset, d.offsetMinutes, d.epochSeconds, d.epochMillis
973971
[[examples-truncate]]
974972
==== Truncating temporal values
975973

974+
The truncate functions in Neo4j allow you to reduce the precision of temporal values by truncating them to a specified component such as `year`, `month`, or `second`.
975+
976976
.Truncate `DATE` values
977977
======
978978
@@ -982,13 +982,13 @@ To truncate `DATE` values, use the xref:functions/temporal/index.adoc#functions-
982982
.Get the first day of the current year:
983983
[source, cypher, role=test-result-skip]
984984
----
985-
RETURN date.truncate('year') AS day
985+
RETURN date.truncate('year') AS firstDay
986986
----
987987
988988
.Result
989989
[role="queryresult",options="header,footer",cols="1*<m"]
990990
|===
991-
| day
991+
| firstDay
992992
993993
| 2022-01-01
994994
@@ -1171,7 +1171,6 @@ RETURN datetime.truncate('week', datetime(), {dayOfWeek: 3}) AS startOfWednesday
11711171
=====
11721172

11731173

1174-
11751174
[[cypher-temporal-durations]]
11761175
== Durations
11771176

0 commit comments

Comments
 (0)