mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-23 04:23:47 +08:00
Update sqlite truncate
This commit is contained in:
@@ -258,6 +258,11 @@ namespace SqlSugar
|
|||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Methods
|
#region Methods
|
||||||
|
public override bool TruncateTable(string tableName)
|
||||||
|
{
|
||||||
|
base.TruncateTable(tableName);
|
||||||
|
return this.Context.Ado.ExecuteCommand($"UPDATE sqlite_sequence SET seq = 0 WHERE name = '{tableName}'") > 0;
|
||||||
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
///by current connection string
|
///by current connection string
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
Reference in New Issue
Block a user