Skip to content

Commit ab6e7a7

Browse files
kyleconroyclaude
andcommitted
Handle string literals and negative numbers in generic DB scoped config
- Add TokenString and TokenMinus cases for generic configuration options - This allows parsing of values like 'quoted_value' and -10 correctly Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 97f4e84 commit ab6e7a7

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

parser/parse_ddl.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3847,8 +3847,8 @@ func (p *Parser) parseAlterDatabaseScopedConfigurationSetStatement(secondary boo
38473847
}
38483848

38493849
var state *ast.IdentifierOrScalarExpression
3850-
// Check if value is an identifier or a number
3851-
if p.curTok.Type == TokenNumber {
3850+
// Check if value is a number, string, negative number, or identifier
3851+
if p.curTok.Type == TokenNumber || p.curTok.Type == TokenString || p.curTok.Type == TokenMinus {
38523852
val, err := p.parseScalarExpression()
38533853
if err != nil {
38543854
return nil, err
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"todo": true}
1+
{}

0 commit comments

Comments
 (0)