Skip to content

Conversation

rsill-neo4j
Copy link
Contributor

No description provided.

| The values of the parameters may be arbitrarily large.
| The values of the parameters may be negative.
| The xref:values-and-types/temporal.adoc#cypher-temporal-accessing-components-durations[components of `DURATION` objects] are individually accessible.
| The `pattern` parameter follows the link:https://docs.oracle.com/en/java/javase/21/docs/api/java.base/java/time/format/DateTimeFormatter.html[Java DateTimeFormatter].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DURATION does not use the Java DatetimeFormatter but our own system. Could we reference to the the Duration Format characters instead as they follow the same system.

| Selecting a `ZONED DATETIME` or `ZONED TIME` as the `time` component and overwriting the timezone will adjust the local time to keep the same point in time.
| `epochSeconds`/`epochMillis` may be used in conjunction with `nanosecond`.
| `datetime(null)` returns null.
| The `pattern` parameter follows the link:https://docs.oracle.com/en/java/javase/21/docs/api/java.base/java/time/format/DateTimeFormatter.html[Java DateTimeFormatter].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we feel this is sufficient mention of the format or should we be more explicit as we are with the format function?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as in, add a link to the format function table? sure

Copy link
Contributor

@JoelBergstrand JoelBergstrand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some questions on how much we should expose the pattern system.

Copy link
Contributor

@JoelBergstrand JoelBergstrand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great!

Copy link
Contributor

@Lojjs Lojjs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some mixed feedback

| The values of the parameters may be arbitrarily large.
| The values of the parameters may be negative.
| The xref:values-and-types/temporal.adoc#cypher-temporal-accessing-components-durations[components of `DURATION` objects] are individually accessible.
| The `pattern` parameter is constructed from xref:functions/temporal/format.adoc#query-functions-temporal-format-duration-types-characters[Allowed characters for duration types].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we want to call it 'pattern argument' rather than 'pattern parameter', as in the table above it is referred to as an argument? If you decide to change this, it also applies to other parts of the PR.

A few of the bullet points above mentions parameter, but they seem to be about the values of the map/the numeric parts of the string in the input argument. It is not really part of this PR but I also feel like that use of the world parameter is also a bit confusing for a user, maybe 'component' would be better (that is what we call it in Example 1)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changing to 'argument' to be consistent with the table(s). also accepting 'component' to make this clearer.

thanks for noticing 👍

| If `from` has a time component and `to` does not, the time component of `to` is assumed to be midnight, and vice versa.
| If `from` has a time zone component and `to` does not, the time zone component of `to` is assumed to be the same as that of `from`, and vice versa.
| If `to` has a date component and `from` does not, the date component of `from` is assumed to be the same as that of `to`, and vice versa.
| The `pattern` parameter follows the link:https://docs.oracle.com/en/java/javase/21/docs/api/java.base/java/time/format/DateTimeFormatter.html[Java DateTimeFormatter].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this really be under duration.between() and not in the other bullet point list under duration()?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

copy-paste error i think :) removed it

Copy link
Contributor

@Lojjs Lojjs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now

| PT45S
| P2012Y2M2DT14H37M21.545S
1+d|Rows: 5
| P5H6M
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
| P5H6M
| PT5H6M

@neo4j-docops-agent
Copy link
Collaborator

neo4j-docops-agent commented Oct 8, 2025

Thanks for the documentation updates.

The preview documentation has now been torn down - reopening this PR will republish it.

@rsill-neo4j rsill-neo4j merged commit 0bec8e4 into dev Oct 8, 2025
5 checks passed
@stefano-ottolenghi stefano-ottolenghi deleted the document-temporal-parsing branch October 14, 2025 13:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants