mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-24 12:59:58 -06:00
Grammar: Allow multiple table keys which are not separated by commas
Fix table definitions like this... CREATE TABLE [player_tech_branches] ( [from_id] INTEGER NOT NULL REFERENCES [techs](id), [to_id] INTEGER NOT NULL REFERENCES [techs](id), UNIQUE ([from_id], [to_id]) PRIMARY KEY ([from_id], [to_id]) ) ...where there are multiple keys which are not separated by commas. This partially fixed EoD's database in issue #63.
This commit is contained in:
@@ -258,7 +258,7 @@ keywordastablename
|
||||
createtable
|
||||
:
|
||||
CREATE (TEMP|TEMPORARY)? TABLE (IF_T NOT EXISTS)? (tablename | keywordastablename)
|
||||
( LPAREN columndef (COMMA columndef)* (COMMA tableconstraint)* RPAREN (WITHOUT ROWID)?
|
||||
( LPAREN columndef (COMMA columndef)* ((COMMA)? tableconstraint)* RPAREN (WITHOUT ROWID)?
|
||||
| AS selectstmt
|
||||
)
|
||||
{#createtable = #([CREATETABLE, "CREATETABLE"], #createtable);}
|
||||
|
||||
Reference in New Issue
Block a user