diff --git a/packages/tools/src/SqlDumper.ts b/packages/tools/src/SqlDumper.ts index c8f551a5..063989a3 100644 --- a/packages/tools/src/SqlDumper.ts +++ b/packages/tools/src/SqlDumper.ts @@ -527,7 +527,7 @@ export class SqlDumper implements AlterProcessor { } truncateTable(name: NamedObjectInfo) { - this.putCmd('^delete ^from %f', name); + this.putCmd('^truncate ^table %f', name); } dropConstraints(table: TableInfo, dropReferences = false) { diff --git a/packages/types/dumper.d.ts b/packages/types/dumper.d.ts index 4b53e8a2..9d35fbde 100644 --- a/packages/types/dumper.d.ts +++ b/packages/types/dumper.d.ts @@ -17,6 +17,7 @@ export interface SqlDumper extends AlterProcessor { endCommand(); allowIdentityInsert(table: NamedObjectInfo, allow: boolean); + truncateTable(table: NamedObjectInfo); beginTransaction(); commitTransaction(); } diff --git a/packages/web/src/appobj/DatabaseObjectAppObject.svelte b/packages/web/src/appobj/DatabaseObjectAppObject.svelte index 7fe147aa..b13cabf6 100644 --- a/packages/web/src/appobj/DatabaseObjectAppObject.svelte +++ b/packages/web/src/appobj/DatabaseObjectAppObject.svelte @@ -1,7 +1,14 @@