0
Dieses mich treibt verrückt. Die folgende Abfrage funktioniert ganz lokal in Ordnung, aber versagt, wenn ich es auf travis-ci testen und wirft die Fehler:Postgresql Abfrage funktioniert lokal, aber nicht auf Travis CI
java.lang.RuntimeException: org.postgresql.util.PSQLException: ERROR: syntax error at or near "select" Position: 39
Hoffentlich jemand etwas sehen kann ich nicht.
Hier meine Tabellen sind:
+----------+---------------+
| ways |
+----------+---------------+
| way_id | bigint |
| node_ids | bigint array |
| rep_lat | float(9) |
| rep_lon | float(9) |
+----------+---------------+
+---------+-----------+
| nodes |
+---------+-----------+
| node_id | bigint |
| lat | float(9) |
| lon | float(9) |
+---------+-----------+
Hier ist meine Frage:
update ways
set (rep_lat, rep_lon) =
(
select lat, lon
from nodes
where nodes.node_id = ways.node_ids[array_length(ways.node_ids, 1)/2]
)