Browse Source

posgres support 6

master
gsd 6 months ago
parent
commit
0eb1b281e4
  1. 2
      src/main/java/app/services/db/DetectService.java

2
src/main/java/app/services/db/DetectService.java

@ -40,7 +40,7 @@ public class DetectService {
public List<SteamID> getAccountsPerSteamID(SteamID steamID) {
List<String> founded_steamid = new ArrayList<>();
for (Map.Entry<String, Server> stringServerEntry : stats.getServers().entrySet()) {
founded_steamid.addAll(jdbcTemplate_ro.query("SELECT steam_id FROM " + stringServerEntry.getValue().getDb() + "." + "user_connections WHERE connect_ip in (SELECT connect_ip FROM " + stringServerEntry.getValue().getDb() + "." + "user_connections WHERE steam_id LIKE ? AND connect_ip NOT LIKE '10.%' GROUP BY connect_ip ORDER BY id DESC) GROUP BY steam_id",
founded_steamid.addAll(jdbcTemplate_ro.query("SELECT steam_id FROM " + stringServerEntry.getValue().getDb() + "." + "user_connections WHERE connect_ip in (SELECT connect_ip FROM " + stringServerEntry.getValue().getDb() + "." + "user_connections WHERE steam_id LIKE ? AND connect_ip NOT LIKE '10.%' GROUP BY connect_ip, id ORDER BY id DESC) GROUP BY steam_id",
new Object[]{steamID.steam2},
(rs, n) -> rs.getString("steam_id")));
}

Loading…
Cancel
Save