Skip to content
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

Fix date-type column formatting #1

Merged
merged 2 commits into from
Feb 13, 2025

Conversation

DeflateAwning
Copy link
Owner

Original PR: adamviola#27

Added Luxon library, which is a dependency of Tabulator for formatting dates, and a simple formatter that outputs DATE columns as "yyyy-MM-dd" in UTC. If necessary, the timezone could be made configurable via extension settings, but I didn't get to that.

Resolves adamviola#17

Test case:

SELECT 
    12 AS random_number,
    DATE '2024-09-22' AS arbitrary_date,
    TIMESTAMP '2024-09-22 15:30:00' AS arbitrary_datetime,
    TIMESTAMP '2024-09-22 00:00:00' AS datetime_with_0_time_should_show_as_full_datetime;

@DeflateAwning DeflateAwning merged commit 7057335 into DeflateAwning:main Feb 13, 2025
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.

"Date" columns are displaying as Datetime columns
2 participants