Skip to content

fix: convert timestamp to date math#695

Merged
adsharma merged 1 commit into
mainfrom
fix/timestamp-interval-conversion
Jul 18, 2026
Merged

fix: convert timestamp to date math#695
adsharma merged 1 commit into
mainfrom
fix/timestamp-interval-conversion

Conversation

@adsharma

@adsharma adsharma commented Jul 18, 2026

Copy link
Copy Markdown
Contributor

Related: #694

Interval::getMicro uses DAYS_PER_YEAR (365) for whole years instead of DAYS_PER_MONTH * 12 (360), matching the documented constants.

@adsharma
adsharma force-pushed the fix/timestamp-interval-conversion branch from 47500fb to ab9c795 Compare July 18, 2026 15:10
…ys conversion

Interval::getMicro and PyQueryResult interval-to-timedelta now use
  days = years * 365 + months * 30 + days
instead of
  days = months * 30 + days

This gives 365 days per whole year instead of 360, matching the
engine's DAYS_PER_YEAR constant (365) vs DAYS_PER_MONTH (30).
@adsharma
adsharma force-pushed the fix/timestamp-interval-conversion branch from ab9c795 to fcda354 Compare July 18, 2026 15:23
@adsharma adsharma changed the title fix: stop converting timezone on TIMESTAMP (without TZ) fix: convert timestamp to date math Jul 18, 2026
@adsharma
adsharma merged commit 2563c37 into main Jul 18, 2026
4 checks passed
@adsharma
adsharma deleted the fix/timestamp-interval-conversion branch July 18, 2026 16:35
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.

1 participant