Derby Connection Problem.
Hi all,
I am trying to establish connection with Derby(Java DB) through Service but am getting following error. "java.lang.ClassNotFoundException: org.apache.derby.jdbc.ClientDriver" Here is the piece of my database connectivity code. --- try { Connection conn; String driver = "org.apache.derby.jdbc.ClientDriver"; Class.forName(driver).newInstance(); writer.println("Connected to the database"); conn.close(); writer.println("Disconnected from database"); } catch (Exception e) { writer.println(e); } --- Guide me how to register my derby database. Is there any other code snipet that you may want to share. Thanks in advance. |
One answer
Are you using standalone or embedded Derby? Since you are asking the question on jazz.net forum, I suppose you are referring to the embedded Derby database of the Jazz applications. In this case, keep in mind that only one JVM can open the Derby database.
Quoted from http://db.apache.org/derby/papers/DerbyTut/embedded_intro.html If you are working on projects not relating to Jazz, you'd better gather information from the general Derby source, such as below. http://db.apache.org/derby/papers/DerbyTut/index.html |
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.