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

regexp_extract docs should highlight its peculiarities #28386

Open
ggevay opened this issue Jul 22, 2024 · 0 comments
Open

regexp_extract docs should highlight its peculiarities #28386

ggevay opened this issue Jul 22, 2024 · 0 comments
Labels
A-ADAPTER Topics related to the ADAPTER layer A-docs Area: documentation

Comments

@ggevay
Copy link
Contributor

ggevay commented Jul 22, 2024

The common theme across all table functions is that they can compute multiple output values for each input row. But regexp_extract seems to be a really special table function in how it returns its multiple output values. Most table functions put their multiple output values in multiple output rows. However, regexp_extract does the following:

  • When used in the FROM clause, it adds multiple columns.
  • When used in the SELECT clause, it seems to be creating a record (in one column).

I'd improve the docs myself, but I'm not sure about various things:

  • Is regexp_extract the only table function with the above properties?
  • Should we even consider it a table function if it's so different from all other table functions, or create a new category for it?
  • Do other databases have something similar? Note that Cockroach and Databricks have a function with the same name, but it only returns one output value, so it doesn't have the above peculiarities.
@ggevay ggevay added the A-docs Area: documentation label Jul 22, 2024
@ggevay ggevay added the A-ADAPTER Topics related to the ADAPTER layer label Jul 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-ADAPTER Topics related to the ADAPTER layer A-docs Area: documentation
Projects
None yet
Development

No branches or pull requests

1 participant