Skip to content

Commit

Permalink
Fix space in table name while droping view (#5916)
Browse files Browse the repository at this point in the history
  • Loading branch information
k-anshul authored Oct 16, 2024
1 parent 66192ad commit 19e042e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/drivers/duckdb/olap.go
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ func (c *connection) dropAndReplace(ctx context.Context, oldName, newName string
existingTyp = "TABLE"
}

err := c.Exec(ctx, &drivers.Statement{Query: fmt.Sprintf("DROP %s IF EXISTS %s", existingTyp, newName)})
err := c.Exec(ctx, &drivers.Statement{Query: fmt.Sprintf("DROP %s IF EXISTS %s", existingTyp, safeSQLName(newName))})
if err != nil {
return err
}
Expand Down

0 comments on commit 19e042e

Please sign in to comment.