| @@ 149-164 (lines=16) @@ | ||
| 146 | * @param string $table_name |
|
| 147 | * @return mixed |
|
| 148 | */ |
|
| 149 | public function optimize_table($table_name) |
|
| 150 | { |
|
| 151 | if ($this->_optimize_table === FALSE) |
|
| 152 | { |
|
| 153 | return ($this->db->db_debug) ? $this->db->display_error('db_unsupported_feature') : FALSE; |
|
| 154 | } |
|
| 155 | ||
| 156 | $query = $this->db->query(sprintf($this->_optimize_table, $this->db->escape_identifiers($table_name))); |
|
| 157 | if ($query !== FALSE) |
|
| 158 | { |
|
| 159 | $query = $query->result_array(); |
|
| 160 | return current($query); |
|
| 161 | } |
|
| 162 | ||
| 163 | return FALSE; |
|
| 164 | } |
|
| 165 | ||
| 166 | // -------------------------------------------------------------------- |
|
| 167 | ||
| @@ 210-225 (lines=16) @@ | ||
| 207 | * @param string $table_name |
|
| 208 | * @return mixed |
|
| 209 | */ |
|
| 210 | public function repair_table($table_name) |
|
| 211 | { |
|
| 212 | if ($this->_repair_table === FALSE) |
|
| 213 | { |
|
| 214 | return ($this->db->db_debug) ? $this->db->display_error('db_unsupported_feature') : FALSE; |
|
| 215 | } |
|
| 216 | ||
| 217 | $query = $this->db->query(sprintf($this->_repair_table, $this->db->escape_identifiers($table_name))); |
|
| 218 | if (is_bool($query)) |
|
| 219 | { |
|
| 220 | return $query; |
|
| 221 | } |
|
| 222 | ||
| 223 | $query = $query->result_array(); |
|
| 224 | return current($query); |
|
| 225 | } |
|
| 226 | ||
| 227 | // -------------------------------------------------------------------- |
|
| 228 | ||