docs: add runnable examples for input_file_name() and file_row_index() - #24634
Open
alamb wants to merge 1 commit into
Open
docs: add runnable examples for input_file_name() and file_row_index()#24634alamb wants to merge 1 commit into
input_file_name() and file_row_index()#24634alamb wants to merge 1 commit into
Conversation
Both functions previously documented a placeholder example (`SELECT input_file_name() FROM t;`) that showed no output and did not illustrate that these functions are per-file metadata resolved during a file scan. Replace them with a complete, verified example that writes a small Parquet file and selects both functions alongside the data columns.
alamb
marked this pull request as ready for review
August 24, 2026 19:10
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #24634 +/- ##
=======================================
Coverage 81.43% 81.43%
=======================================
Files 1118 1118
Lines 399414 399414
Branches 399414 399414
=======================================
Hits 325278 325278
+ Misses 55145 55141 -4
- Partials 18991 18995 +4 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Rationale for this change
While writing a blog post
Which mentiones
file_row_index()andinput_file_name()-- I added a simple example for the post and I think it would help to have docs in the main site too.What changes are included in this PR?
Replaces the
sql_examplewithThe same example is used for both functions, since showing them together is likely common and I think makes it clear what they do
Are these changes tested?
By CI
Are there any user-facing changes?
Yes, but documentation only -- the rendered examples for
input_file_name()and
file_row_index()in the SQL function reference. No API or behaviorchanges.