private static long getTilesCount(Mbtiles db) throws SQLException {
    try (var statement = db.connection().createStatement()) {
      var rs = statement.executeQuery("select count(*) from tiles_shallow");
      rs.next();
      return rs.getLong(1);
    } catch (Exception e) {
      try (var statement = db.connection().createStatement()) {
        var rs = statement.executeQuery("select count(*) from tiles");
        rs.next();
        return rs.getLong(1);
      }
    }
  }
A utility to compare two mbtiles files.
<p>
See {@link VectorTileFeatureForCmp} for comparison rules. The results planetiler produces are not necessarily stable,
so sometimes a few feature may be different in one tile. Also POI coordinates may sometimes differ slightly. This
should get fixed in https://github.com/onthegomap/planetiler/issues/215
<p>
=> The tool helps to see if two mbtiles files are (mostly) identical.
planetiler-core/src/main/java/com/onthegomap/planetiler/mbtiles/Compare.java