public function count($column = NULL)
	{
		if ($column) {
			return $this->sum($column);
		}

		if ($this->result) {
			return count($this->result);
		}

		list(, $criteria, $options) = $this->queryBuilder->buildSelectQuery();

		return $this->query->count($this->name, $criteria, $options);
	}