public function current($sequence) { $result = $this->_connection->execute("SELECT id FROM sequences WHERE name=?", $sequence); return (int) $result[0]['id'] - 1; }