Commit 62ee58f
committed
fix: recognize BEGIN READ WRITE/ONLY as transaction statements
The statement splitter checks if a keyword after BEGIN is a transaction
keyword to distinguish transaction statements from PL/SQL blocks. READ,
ONLY and WRITE were missing from this list, causing Redshift's
BEGIN READ WRITE to be treated as a block start — split() would return
the entire content as one statement.
Add READ, ONLY, WRITE to the transaction keyword list so
BEGIN READ WRITE and BEGIN READ ONLY are correctly split as standalone
transaction statements.
Fixes: #843
Signed-off-by: Vincent Gao <gaobing1230@gmail.com>1 parent f80af6a commit 62ee58f
2 files changed
Lines changed: 26 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
135 | | - | |
| 135 | + | |
| 136 | + | |
136 | 137 | | |
137 | 138 | | |
138 | 139 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
286 | 286 | | |
287 | 287 | | |
288 | 288 | | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
289 | 313 | | |
290 | 314 | | |
291 | 315 | | |
| |||
0 commit comments