Skip to content

Conversation

zfarrell
Copy link
Collaborator

Implements parse_statements() table and scalar functions, and num_statements() scalar function to parse multi-statement SQL strings. The functions extract individual statements or count them using DuckDB's native parser.

Resolves #8 .

Implements parse_statements() table and scalar functions, and num_statements() scalar function to parse multi-statement SQL strings. The functions extract individual statements or count them using DuckDB's native parser.

Features:
- parse_statements() table function returns each statement as a row
- parse_statements() scalar function returns list of statement strings
- num_statements() returns count of statements in SQL string
- Comprehensive test coverage for all functions
- Updated documentation with examples and usage
@zfarrell zfarrell merged commit 0c74f1b into main Sep 24, 2025
44 checks passed
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.

Function to return number of statements (or even better, the split statements)

1 participant