Safe 9 lines of code by introducing new server specific snippets spEmptyTable and spCurrentUserHost.

This commit is contained in:
Ansgar Becker
2012-03-26 18:43:00 +00:00
parent 6703f20711
commit c2699b3443
2 changed files with 9 additions and 18 deletions

View File

@ -3298,10 +3298,7 @@ begin
EnableProgress(Objects.Count);
try
for TableOrView in Objects do begin
case TableOrView.Connection.Parameters.NetTypeGroup of
ngMySQL: TableOrView.Connection.Query('TRUNCATE ' + TableOrView.QuotedName);
ngMSSQL: TableOrView.Connection.Query('DELETE FROM ' + TableOrView.QuotedName);
end;
TableOrView.Connection.Query(TableOrView.Connection.GetSQLSpecifity(spEmptyTable) + TableOrView.QuotedName);
ProgressStep;
end;
actRefresh.Execute;