Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

jasonfrye's avatar

jasonfrye liked a comment+100 XP

2w ago

Best way to truncate very large data table?

INSERT INTO change_logs_backup SELECT * FROM change_logs;

It would take forever. For backup I'd rename change_logs to change_logs_backup and create change_logs from scratch. Same result but almost instantly.