Hello list,
If you let me, I'd modify the code to use TRUNCATE instead of DELETE when emptying tables if MySQL 4 is used since this is a much faster way: The DELETE command deletes the table content row by row while TRUNCATE drops and recreates the table. Some doc about this: http://www.mysql.com/doc/T/R/TRUNCATE.html
Alexander
Alexander,
good idea. However is it possible to check for locks: "Not transaction-safe; you will get an error if you have an active transaction or an active table lock. "
Rabus a écrit :
Hello list,
If you let me, I'd modify the code to use TRUNCATE instead of DELETE when emptying tables if MySQL 4 is used since this is a much faster way: The DELETE command deletes the table content row by row while TRUNCATE drops and recreates the table. Some doc about this: http://www.mysql.com/doc/T/R/TRUNCATE.html
Alexander
Phpmyadmin-devel mailing list Phpmyadmin-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/phpmyadmin-devel
----- Original Message ----- From: "Marc Delisle" DelislMa@CollegeSherbrooke.qc.ca
good idea. However is it possible to check for locks: "Not transaction-safe; you will get an error if you have an active
transaction or an active table
lock. "
I don't know yet, I'm going to browse a bit through the docs... But if not, it should work like this: If TRUNCATE fails, try DELETE instead.
Alexander