mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-07-23 01:14:31 +02:00
create-table now supports multiple --pk, refs #620
This commit is contained in:
parent
1dc5da3e5d
commit
23be5be1dc
3 changed files with 13 additions and 3 deletions
|
|
@ -1180,6 +1180,14 @@ def test_upsert_alter(db_path, tmpdir):
|
|||
["age", "integer", "--default", "age", "3"],
|
||||
("CREATE TABLE [t] (\n" " [age] INTEGER DEFAULT '3'\n" ")"),
|
||||
),
|
||||
# Compound primary key
|
||||
(
|
||||
["category", "text", "name", "text", "--pk", "category", "--pk", "name"],
|
||||
(
|
||||
"CREATE TABLE [t] (\n [category] TEXT,\n [name] TEXT,\n"
|
||||
" PRIMARY KEY ([category], [name])\n)"
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
def test_create_table(args, schema):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue