CodeIgniter Forums
$this->dbutil->optimize_table('table_name') doesn't seem to work. - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: $this->dbutil->optimize_table('table_name') doesn't seem to work. (/showthread.php?tid=52352)



$this->dbutil->optimize_table('table_name') doesn't seem to work. - El Forum - 06-07-2012

[eluser]Unknown[/eluser]
I am trying to use $this->dbutil->optimize_table('table_name') to optimise tables in my database.

I don't get any errors returned but there is no change in the database size. If I run a manual Optimise through phpMyAdmin, then a considerable amount of space (more than 10%... it's a busy database) is freed up.

Can anyone give pointers on what may be happening, or are the SQL Optimise and phpMyAdmin manual process different in what they actually do.

My code is quite simple (just this command), and I am running a small $this->db->get... to ensure the correct database is current.

Any help would be appreciated...

Cheers