createDefaultValueSelect creates a SELECT 'value' AS name statement
(paramName, value string)
| 499 | // Since we can't change the AST node type, we'll need to |
| 500 | // handle this at a different level or use a workaround. |
| 501 | // For now, let's set a flag and handle in the transpiler. |
| 502 | changed = true |
| 503 | } |
| 504 | } |
| 505 | |
| 506 | case *pg_query.Node_DiscardStmt: |
| 507 | // DISCARD ALL/PLANS/SEQUENCES/TEMP - silently ignore |
| 508 | result.IsIgnoredSet = true |
| 509 | return true, nil |
| 510 | |
| 511 | case *pg_query.Node_TransactionStmt: |
| 512 | // Handle BEGIN/START TRANSACTION with isolation level |
| 513 | // DuckDB doesn't support ISOLATION LEVEL syntax, so strip it |
| 514 | if n.TransactionStmt != nil { |
| 515 | // Check if this has options (like ISOLATION LEVEL) |
| 516 | if len(n.TransactionStmt.Options) > 0 { |
| 517 | // Clear the options to convert to simple BEGIN |
| 518 | n.TransactionStmt.Options = nil |
| 519 | changed = true |
| 520 | } |
| 521 | } |
| 522 | |
| 523 | case *pg_query.Node_VariableShowStmt: |
| 524 | if n.VariableShowStmt != nil { |
| 525 | paramName := strings.ToLower(n.VariableShowStmt.Name) |