database - Delete all the records from a table -
how can delete records table in delphi? not allowed use loop this:
for k:=1 table1.recordcount begin table1.last; table1.delete; end; is there solutions?
the best way accomplish sql database perform delete directly on server, without moving client side cursor. way end issue several delete commands, 1 each record, when single delete command can delete records @ once.
even better, databases has truncate command (that's oracle, there can equivalent command other dbs) can empty whole table without generating rollback data, faster , requires less resources on server - long sure don't need rollback command later.
if database not sql database, documentation tell best way empty tables.
Comments
Post a Comment