Help with Informix JDBC driver
Posted in 1998
Topics: Connectivity: ODBC / JDBC / .NET, Security, Permissions & Auditing, Java & JDBC Development
Dear there, We are now using the Informix JDBC driver, we used the following code to try to contact with the database, private static final String dbDriverName = "informix.api.jdbc.JDBCDriver"; private static final String dbLocation = "jdbc:informix-api-direct"; private static final String dbName = "group3@camilla_ius_net"; private static final String dbUserName = "username"; private static final String dbUserPassword = "password"; String connectString = dbLocation + ":" + ";database=" + dbName + ";user=" + dbUserName + ";password=" + dbUserPassword; dbConnection= DriverManager.getConnection(connectString); We got the following error message informix.api.jdbc.JDBCException: XIX000:-1804:Invalid database environment. informix.api.jdbc.JDBCException: XIX000:-1804:Invalid database environment. at informix.api.jdbc.JDBCConnection.<init>(JDBCConnection.java:33) at informix.api.jdbc.JDBCDriver.connect(JDBCDriver.java:92) at java.sql.DriverManager.getConnection(DriverManager.java:91) at java.sql.DriverManager.getConnection(DriverManager.java:149) at commerce.CommerceRequest.dbStartTransaction(CommerceRequest.java:41) at commerce.AddUserRequest.run(AddUserRequest.java:48) If you use the finderr 1804, we got -1804 Invalid database environment. The database server cannot connect to the database environment that you specified. The server cannot locate either the database server or the database that you specified. Check the syntax of your statement. If you are specifying a database server, you must use the @ sign. You cannot use //. Is someone there know whether the above syntax is correct, what might be problem? Thanks, Qiang Cao