function onQuery($query, $params) { if (substr($query, 0, 6) !== 'SELECT') { $this->needReset = true; } $this->queries[] = str_replace('"', '`', $query); $this->params[] = $params; }