public function reset()
    {
        $this->queryType = null;
        $this->offset = 0;
        $this->limit = null;
        $this->joins = array();
        $this->fields = array();
        $this->fromTable = null;
        $this->wheres = array();
        $this->orderBy = null;
        $this->groupBy = array();
        $this->having = array();
        return $this;
    }