public function query($query, $args = [], $type = 'object') { // replace bool_and $query = preg_replace('/(bool_and\\((.*?))\\)/i', 'max(\\2)', $query); if ($args) { foreach ($args as $k => $v) { if ($v === true) { $args[$k] = '1'; } elseif ($v === false) { $args[$k] = '0'; } } } return parent::query($query, $args, $type); }
public function exec($query) { $query = str_replace('`', '"', $query); return parent::exec($query); }