Skip to content

datetime: add interval support #205

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 11, 2022

Conversation

oleg-jukovec
Copy link
Collaborator

The patch adds interval [1] support for datetime. Except encoding/decoding interval values from MessagePack, it adds a several functions for addition and substraction Interval and Datetime types in GoLang. Reproducing, thus, arithmetic operations from the Lua implementation [2].

  1. https://github.com/tarantool/tarantool/wiki/Datetime-Internals#interval-arithmetic
  2. https://github.com/tarantool/tarantool/wiki/Datetime-Internals#arithmetic-operations

What has been done? Why? What problem is being solved?

I didn't forget about (remove if it is not applicable):

Related issues:

Closes #165

@oleg-jukovec oleg-jukovec force-pushed the oleg-jukovec/gh-165-interval-support branch from 248a37e to 34d5698 Compare August 9, 2022 14:02
@oleg-jukovec oleg-jukovec marked this pull request as ready for review August 9, 2022 14:25
Copy link
Member

@DifferentialOrange DifferentialOrange left a comment

Choose a reason for hiding this comment

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

Seems nice, left a few questions

@oleg-jukovec oleg-jukovec force-pushed the oleg-jukovec/gh-165-interval-support branch 5 times, most recently from e0b771b to c43af32 Compare August 10, 2022 11:11
Copy link

@vr009 vr009 left a comment

Choose a reason for hiding this comment

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

LGTM

@oleg-jukovec oleg-jukovec force-pushed the oleg-jukovec/gh-165-interval-support branch 2 times, most recently from 45642b7 to 3fb48f2 Compare August 11, 2022 09:42
The patch adds interval [1] support for datetime. Except
encoding/decoding interval values from MessagePack, it adds a several
functions for addition and substraction Interval and Datetime types
in GoLang. Reproducing, thus, arithmetic operations from the Lua
implementation [2].

1. https://github.com/tarantool/tarantool/wiki/Datetime-Internals#interval-arithmetic
2. https://github.com/tarantool/tarantool/wiki/Datetime-Internals#arithmetic-operations

Closes #165
@oleg-jukovec oleg-jukovec force-pushed the oleg-jukovec/gh-165-interval-support branch from 3fb48f2 to 8774e55 Compare August 11, 2022 11:02
@oleg-jukovec oleg-jukovec merged commit ab1fb93 into master Aug 11, 2022
@oleg-jukovec oleg-jukovec deleted the oleg-jukovec/gh-165-interval-support branch August 11, 2022 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support interval type (difference between two datetimes)
3 participants