This is an automated email from the ASF dual-hosted git repository.

adrabble pushed a commit to branch 
530-order-by-size-of-ip-range-in-the-http-iploc-server
in repository https://gitbox.apache.org/repos/asf/incubator-baremaps.git


The following commit(s) were added to 
refs/heads/530-order-by-size-of-ip-range-in-the-http-iploc-server by this push:
     new 2ce41494 Sort by IP start DESC then IP end ASC
2ce41494 is described below

commit 2ce4149446287908f8cc5ed8dd5f0718e2ae9e7f
Author: Antoine Drabble <[email protected]>
AuthorDate: Wed Nov 30 13:50:09 2022 +0100

    Sort by IP start DESC then IP end ASC
---
 .../apache/baremaps/iploc/database/InetnumLocationDaoSqliteImpl.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/baremaps-core/src/main/java/org/apache/baremaps/iploc/database/InetnumLocationDaoSqliteImpl.java
 
b/baremaps-core/src/main/java/org/apache/baremaps/iploc/database/InetnumLocationDaoSqliteImpl.java
index b7b86ac4..51a9e717 100644
--- 
a/baremaps-core/src/main/java/org/apache/baremaps/iploc/database/InetnumLocationDaoSqliteImpl.java
+++ 
b/baremaps-core/src/main/java/org/apache/baremaps/iploc/database/InetnumLocationDaoSqliteImpl.java
@@ -43,7 +43,7 @@ public final class InetnumLocationDaoSqliteImpl implements 
InetnumLocationDao {
 
   private static final String SELECT_ALL_BY_IP_SQL = "SELECT id, address, "
       + "ip_start, ip_end, latitude, longitude, network, "
-      + "country FROM inetnum_locations WHERE ip_start <= ? AND ip_end >= ? 
ORDER BY ip_start DESC;";
+      + "country FROM inetnum_locations WHERE ip_start <= ? AND ip_end >= ? 
ORDER BY ip_start DESC, ip_end ASC;";
 
   private static final Logger logger = 
LoggerFactory.getLogger(InetnumLocationDaoSqliteImpl.class);
 

Reply via email to