diff --git a/lib/ClustersBackend/PlacesBackend.php b/lib/ClustersBackend/PlacesBackend.php index e1338dd1..12923262 100644 --- a/lib/ClustersBackend/PlacesBackend.php +++ b/lib/ClustersBackend/PlacesBackend.php @@ -72,7 +72,7 @@ class PlacesBackend extends Backend $query->select('e.osm_id', 'e.name', 'e.other_names', $count)->from('memories_planet', 'e'); // WHERE these are not special clusters (e.g. timezone) - $query->where($query->expr()->gt('e.admin_level', $query->createNamedParameter(0))); + $query->where($query->expr()->gt('e.admin_level', $query->createNamedParameter(0, \PDO::PARAM_INT))); // WHERE there are items with this osm_id $query->innerJoin('e', 'memories_places', 'mp', $query->expr()->eq('mp.osm_id', 'e.osm_id')); diff --git a/lib/Db/TimelineQuerySingleItem.php b/lib/Db/TimelineQuerySingleItem.php index d5319b43..673de94c 100644 --- a/lib/Db/TimelineQuerySingleItem.php +++ b/lib/Db/TimelineQuerySingleItem.php @@ -76,7 +76,7 @@ trait TimelineQuerySingleItem ->from('memories_places', 'mp') ->innerJoin('mp', 'memories_planet', 'e', $qb->expr()->eq('mp.osm_id', 'e.osm_id')) ->where($qb->expr()->eq('mp.fileid', $qb->createNamedParameter($id, \PDO::PARAM_INT))) - ->andWhere($qb->expr()->gt('e.admin_level', $qb->createNamedParameter(0))) + ->andWhere($qb->expr()->gt('e.admin_level', $qb->createNamedParameter(0, \PDO::PARAM_INT))) ->orderBy('e.admin_level', 'DESC') ;