MySQL Forums
Forum List  »  PHP

Re: Truncate not working
Posted by: Georg Richter
Date: March 24, 2006 11:23PM

from http://dev.mysql.com/doc/refman/5.0/en/truncate.html

For InnoDB before version 5.0.3, TRUNCATE TABLE is mapped to DELETE, so there is no difference. Starting with MySQL 5.0.3, fast TRUNCATE TABLE is available. However, the operation is still mapped to DELETE if there are foreign key constraints that reference the table. (When fast truncate is used, it resets any AUTO_INCREMENT counter. From MySQL 5.0.13 on, the AUTO_INCREMENT counter is reset by TRUNCATE TABLE, regardless of whether there is a foreign key constraint.)

Options: ReplyQuote


Subject
Written By
Posted
March 24, 2006 10:19PM
Re: Truncate not working
March 24, 2006 11:23PM
March 25, 2006 07:32AM
March 25, 2006 07:33AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.