mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-09-28 04:44:26 +02:00
Move sqls=[] closer to where it is populated
This commit is contained in:
parent
9388edf57a
commit
433813612f
1 changed files with 1 additions and 1 deletions
|
|
@ -1570,7 +1570,6 @@ class Table(Queryable):
|
||||||
new_column_pairs.append((new_name, type_))
|
new_column_pairs.append((new_name, type_))
|
||||||
copy_from_to[name] = new_name
|
copy_from_to[name] = new_name
|
||||||
|
|
||||||
sqls = []
|
|
||||||
if pk is DEFAULT:
|
if pk is DEFAULT:
|
||||||
pks_renamed = tuple(
|
pks_renamed = tuple(
|
||||||
rename.get(p.name) or p.name for p in self.columns if p.is_pk
|
rename.get(p.name) or p.name for p in self.columns if p.is_pk
|
||||||
|
|
@ -1624,6 +1623,7 @@ class Table(Queryable):
|
||||||
if column_order is not None:
|
if column_order is not None:
|
||||||
column_order = [rename.get(col) or col for col in column_order]
|
column_order = [rename.get(col) or col for col in column_order]
|
||||||
|
|
||||||
|
sqls = []
|
||||||
sqls.append(
|
sqls.append(
|
||||||
self.db.create_table_sql(
|
self.db.create_table_sql(
|
||||||
new_table_name,
|
new_table_name,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue