[MDEV-17707] the PRIMARY KEY attribute for a field does not accept TYPE to chose the index type Created: 2018-11-14 Updated: 2021-05-11 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Parser |
| Fix Version/s: | None |
| Type: | Task | Priority: | Minor |
| Reporter: | Axel Schwenke | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This statement
makes c1 the primary key and uses the default index type (HASH for MEMORY engine). If we want to use a BTREE index instead, then this does not work:
the SQL parser bails out at 'TYPE BTREE' If written like so, it works again:
The request is to extend the parser to accept an index TYPE when a column definition contains an attribute that would add an index for that column. That is not just PRIMARY KEY, but also UNIQUE. |