//now search for housenumber, if housenumber provided
if ($this->sHouseNumber && !empty($aResults)) {
$aNamedPlaceIDs = $aResults;
- $aResults = $this->queryHouseNumber($oDB, $aNamedPlaceIDs, $iLimit);
+ $aResults = $this->queryHouseNumber($oDB, $aNamedPlaceIDs);
if (empty($aResults) && $this->looksLikeFullAddress()) {
$aResults = $aNamedPlaceIDs;
return $aResults;
}
- private function queryHouseNumber(&$oDB, $aRoadPlaceIDs, $iLimit)
+ private function queryHouseNumber(&$oDB, $aRoadPlaceIDs)
{
$aResults = array();
$sPlaceIDs = Result::joinIdsByTable($aRoadPlaceIDs, Result::TABLE_PLACEX);
$sSQL .= 'WHERE parent_place_id in ('.$sPlaceIDs.')';
$sSQL .= " AND transliteration(housenumber) ~* E'".$sHouseNumberRegex."'";
$sSQL .= $this->oContext->excludeSQL(' AND place_id');
- $sSQL .= " LIMIT $iLimit";
Debug::printSQL($sSQL);
$sSQL .= $iHousenumber.'>=startnumber and ';
$sSQL .= $iHousenumber.'<=endnumber';
$sSQL .= $this->oContext->excludeSQL(' AND place_id');
- $sSQL .= " limit $iLimit";
Debug::printSQL($sSQL);
$sSQL .= ' WHERE parent_place_id in ('.$sPlaceIDs.')';
$sSQL .= " AND housenumber = '".$this->sHouseNumber."'";
$sSQL .= $this->oContext->excludeSQL(' AND place_id');
- $sSQL .= " limit $iLimit";
Debug::printSQL($sSQL);
$sSQL .= $iHousenumber.'>=startnumber and ';
$sSQL .= $iHousenumber.'<=endnumber';
$sSQL .= $this->oContext->excludeSQL(' AND place_id');
- $sSQL .= " limit $iLimit";
Debug::printSQL($sSQL);