Skip to content

Fix nested commas in column definition example - #902

Open
RamiNoodle733 wants to merge 1 commit into
andialbrecht:masterfrom
RamiNoodle733:fix/column-def-nested-comma-731
Open

RamiNoodle733 wants to merge 1 commit into
andialbrecht:masterfrom
RamiNoodle733:fix/column-def-nested-comma-731

Conversation

@RamiNoodle733

Copy link
Copy Markdown

Fixes #731.

extract_definitions() tracks nested parenthesis depth, but currently splits on every comma regardless of that depth and also drops nested opening parentheses. As a result, types such as decimal(30, 8) are incorrectly treated as two column definitions.

This makes commas delimit definitions only at the outer column-list level and preserves nested parentheses in the collected definition. The example SQL now includes decimal(30, 8) so the reported case is exercised directly.

Validation: I reviewed the focused branch diff against current upstream master. I attempted a local executable check, but this automation runtime does not have sqlparse installed, so no local test result is claimed.

AI assistance was used to inspect the issue and implementation and prepare the focused fix.

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.

example column_defs_lowlevel bug

1 participant