Repository navigation
Commit 56a0bf6
committed
fix(bigquery): keep a column's and a struct field's OPTIONS
A table column's OPTIONS (...) and a struct field's OPTIONS (...) were
read and dropped, so CREATE TABLE d.t (a INT64 OPTIONS(description='ab'))
and the same with 'cd', or with no OPTIONS, gave one tree. ALTER TABLE
... ADD COLUMN had the same loss.
The column keeps its entries in ColumnDef.options and the struct field
appends them to StructField.options after NOT NULL, the fields other
dialects already fill. The other OPTIONS lists the parser reads without
a field (constraint OPTIONS, UNDROP and SELECT WITH ... OPTIONS) are
opaque gaps that keep their text.1 parent b938ec5 commit 56a0bf6
3 files changed
Lines changed: 32 additions & 2 deletions
File tree
- crates/sqlquack-syntax-bigquery/src/parse
- _helpers
- commands
- values
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
502 | 502 | | |
503 | 503 | | |
504 | 504 | | |
505 | | - | |
| 505 | + | |
506 | 506 | | |
507 | 507 | | |
508 | 508 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
258 | 258 | | |
259 | 259 | | |
260 | 260 | | |
261 | | - | |
| 261 | + | |
262 | 262 | | |
263 | 263 | | |
264 | 264 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1477 | 1477 | | |
1478 | 1478 | | |
1479 | 1479 | | |
| 1480 | + | |
| 1481 | + | |
| 1482 | + | |
| 1483 | + | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
| 1487 | + | |
| 1488 | + | |
| 1489 | + | |
| 1490 | + | |
| 1491 | + | |
| 1492 | + | |
| 1493 | + | |
| 1494 | + | |
| 1495 | + | |
| 1496 | + | |
| 1497 | + | |
| 1498 | + | |
| 1499 | + | |
| 1500 | + | |
| 1501 | + | |
| 1502 | + | |
| 1503 | + | |
| 1504 | + | |
| 1505 | + | |
| 1506 | + | |
| 1507 | + | |
| 1508 | + | |
| 1509 | + | |
1480 | 1510 | | |
1481 | 1511 | | |
1482 | 1512 | | |
| |||
0 commit comments