Michael Ekdal

Results 3 comments of Michael Ekdal

package Jvakt; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.Statement; public class test07 { public static void main(String[] args) throws Exception { try (Connection con = DriverManager.getConnection( "jdbc:postgresql://localhost/Jvakt", "test", "test"))...

Testing 42.7.6.jar and the same error persists :) . **This statement:** _Statement stmt = conn.createStatement(ResultSet.CONCUR_READ_ONLY,ResultSet.TYPE_FORWARD_ONLY,ResultSet.CLOSE_CURSORS_AT_COMMIT );_ **Trigger this error:** _org.postgresql.util.PSQLException: Unknown value for ResultSet type Unknown value for ResultSet type_...

Changed the order of the parameters of the createStatement to conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,ResultSet.CONCUR_READ_ONLY,ResultSet.HOLD_CURSORS_OVER_COMMIT ); and now it works.