Skip to content

feat: add conversions between snowflake id and dateTime(dateTime64)#27704

Merged
kssenii merged 6 commits intoClickHouse:masterfrom
jasine:master
Aug 20, 2021
Merged

feat: add conversions between snowflake id and dateTime(dateTime64)#27704
kssenii merged 6 commits intoClickHouse:masterfrom
jasine:master

Conversation

@jasine
Copy link
Copy Markdown
Contributor

@jasine jasine commented Aug 15, 2021

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en

Changelog category (leave one):

  • New Feature

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

add conversion functions between snowflake id and dateTime(dateTime64) Close #27058

Detailed description / Documentation draft:

following functions added

snowflakeToDateTime
dateTimeToSnowflake
snowflakeToDateTime64
dateTime64ToSnowflake

By adding documentation, you'll allow users to try your new feature immediately, not when someone else will have time to document it later. Documentation is necessary for all features that affect user experience in any way. You can add brief documentation draft above, or add documentation right into your patch as Markdown files in docs folder.

If you are doing this for the first time, it's recommended to read the lightweight Contributing to ClickHouse Documentation guide first.

Information about CI checks: https://clickhouse.tech/docs/en/development/continuous-integration/

@robot-clickhouse robot-clickhouse added doc-alert pr-feature Pull request with new product feature labels Aug 15, 2021
@jasine jasine changed the title feat: add conversion between snowflake id and datetime feat: add conversions between snowflake id and dateTime(dateTime64) Aug 15, 2021
@kssenii kssenii self-assigned this Aug 15, 2021
@kssenii
Copy link
Copy Markdown
Member

kssenii commented Aug 15, 2021

Please, add tests (functional test in tests/queries/0_stateless/ directory, see link)

@jasine
Copy link
Copy Markdown
Contributor Author

jasine commented Aug 16, 2021

Please, add tests (functional test in tests/queries/0_stateless/ directory, see link)

@kssenii tests and docs added, please review, thanks.

@jameingh
Copy link
Copy Markdown

@jasine Where is this code now?I can't find it in any branch.
image

@jasine
Copy link
Copy Markdown
Contributor Author

jasine commented Jan 12, 2022

@jameingh I force pushed when resolving conflict

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-feature Pull request with new product feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

snowflake id (not to confuse with Snowflake service) time extract and convert functions

4 participants