Reputation: 807
Do the performance of select query decreases if I remove the data from a table using delete ?Is there any performance difference if I use truncate to clear the entire table in comparison with delete the selected rows.
Upvotes: 0
Views: 185
Reputation: 3196
http://dev.mysql.com/doc/refman/5.1/en/truncate-table.html
Truncate operations drop and re-create the table, which is much faster than deleting rows one by one, particularly for large tables.
also: http://www.softstuff-consulting.com/kbase/showkb.asp?id=15
Upvotes: 1