Skip to content

Add range table function #14830

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 3 commits into from
Feb 24, 2025
Merged

Add range table function #14830

merged 3 commits into from
Feb 24, 2025

Conversation

simonvandel
Copy link
Contributor

Which issue does this PR close?

Part of #10177. It does not close it, as there is no support for timestamp arguments.

Rationale for this change

generate_series currently exists as a table function, so it would be natural to also support range.

What changes are included in this PR?

  • Parametize enough of the existing implementation of generate_series such that it can be used to implement range.

Are these changes tested?

Yes, copied the existing slt tests for generate_series (modulo where/join/order by variations).

Are there any user-facing changes?

Support for queries like

SELECT * FROM range(1,10);

@github-actions github-actions bot added the sqllogictest SQL Logic Tests (.slt) label Feb 22, 2025
Copy link
Member

@xudong963 xudong963 left a comment

Choose a reason for hiding this comment

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

Thank you @simonvandel , love it.

@alamb alamb merged commit a235276 into apache:main Feb 24, 2025
24 checks passed
@alamb
Copy link
Contributor

alamb commented Feb 24, 2025

🚀

ozankabak pushed a commit to synnada-ai/datafusion-upstream that referenced this pull request Feb 25, 2025
* extract name

* extract inclusive

* range table function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sqllogictest SQL Logic Tests (.slt)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants