Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

problem with connection to db with netbeans and derby

730895May 6 2011 — edited May 6 2011
Hello all!
I am trying to create a database programmatically with java and derby drive using netbeans.
when I run this code:
Class.forName("org.apache.derby.jdbc.EmbeddedDriver");
              Properties connectionProps = new Properties();
    connectionProps.put("user", "demo");
    connectionProps.put("password", "demo");
     con = DriverManager.getConnection("jdbc:derby:C:/Documents and Settings/Administrator/.netbeans-derby/simple;create=true", connectionProps);
  con.commit();
there arent any errors but when I am trying to connect to the db that I created the netbeans message is:
unable to connect. sqlcode -1 sqlstate XJ040 THE DATABASE WAS CREATED BY OR UPGRADED BY VERSION 10.6
thanks for helping

Edited by: vitaly87 on 04:48 06/05/2011
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 3 2011
Added on May 6 2011
0 comments
163 views