I am trying to pass an array of geometry to a postgis function using JDBC with JAVA:
CallableStatement proc = conn.prepareCall("{ ? = call somefunc(?) }");
proc.registerOutParameter(1, 7);
PGgeometry[] arr = new PGgeometry[2];
arr[0] = a;
arr[1] = b;
proc.setArray(2, conn.createArrayOf("geometry", arr));
proc.execute();
a,b are valid PGgeometry types. I am getting this exception:
Exception in thread "main" java.lang.AbstractMethodError: org.postgresql.jdbc3g.Jdbc3gConnection.createArrayOf(Ljava/lang/String;[Ljava/lang/Object;)Ljava/sql/Array;
Is this even possible to do? I found no good answer for that.
Thanks!