public function GetCountSQL($criteria)
	{
		$sql = "select count(1) as counter ";
	
		$sql .= $this->GetTableJoinSQL($criteria);
	
		$sql .= $criteria->GetJoin();
	
		$sql .= $this->GetWhereSQL($criteria);
		
		$criteria->Reset();
	
		return $sql;
	}
public function GetCountSQL($criteria)
	{
		$sql = "select count(1) as counter ";
	
		$sql .= $this->GetTableJoinSQL($criteria);
	
		$sql .= $criteria->GetJoin();
	
		$sql .= $this->GetWhereSQL($criteria);
		
		$criteria->Reset();
	
		return $sql;
	}
public function GetCountSQL ( $ criteria ) { $ sql = "select count(1) as counter " ; $ sql .= $ this -> GetTableJoinSQL ( $ criteria ) ; $ sql .= $ criteria -> GetJoin ( ) ; $ sql .= $ this -> GetWhereSQL ( $ criteria ) ; $ criteria -> Reset ( ) ; return $ sql ; }
Builds a SQL statement from the given criteria object to count the results and resets the Criteria

@param Criteria $criteria
@return string fully formed SQL statement
Builds a SQL statement from the given criteria object to count the results and resets the Criteria