mysql clear table code example
Example 1: mysql flush privileges
FLUSH PRIVILEGES;
Example 2: clear a table in mysql
truncate tableName
Example 3: mysql empty a table
TRUNCATE TABLE tblYourTable;
SET FOREIGN_KEY_CHECKS = 0;
TRUNCATE YourTable1;
TRUNCATE YourTable2;
SET FOREIGN_KEY_CHECKS = 1;
DELETE FROM tblYourTable WHERE condition;
DELETE FROM tblYourTable LIMIT row_count;
Example 4: remove all records from table mysql
DELETE from tableName;
TRUNCATE tableName;
Example 5: delete all content in table mysql
TRUNCATE tablename