Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 6 of 6

Thread: Help with embedding database

  1. #1
    Junior Member
    Join Date
    Nov 2011
    Posts
    3
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Help with embedding database

    I'm having a hard time grasping the idea of embedding a database into the application. I've read various tutorials and guides and I'm still a bit lost. I've created the shell of the program in NetBeans and i have yet to embed the database. I was wondering if anyone could help me out here and also suggest an embedded database (ie derby) to use. I'm sorry if I'm not making much sense but I am quite confused.

    Thanks

    Please if you're going to reply, don't reply with a let me google that for you link.


  2. #2
    Junior Member
    Join Date
    Nov 2011
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Help with embedding database

    Hi!
    You can give HSQLDB a try. It's a clear example of embedded DB and we have successfully used it in several projects.
    Basically, you don't need to install the DB engine. Just deliver the hsqldb.jar with your application, as you would do with the rest of libraries you use.

  3. #3
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,320
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: Help with embedding database

    You question is a bit open ended, so what exactly are you stuck with? Did you try to embed a database by adding the appropriate library? Did you try loading the driver class? Did you try creating a database? See the following if you are considering Derby
    Step 3: Embedded Derby

  4. #4
    Junior Member
    Join Date
    Nov 2011
    Posts
    3
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help with embedding database

    im stuck with embedding the database into the application. im not exactly sure how to add the library into the application :/
    Last edited by MrT; November 24th, 2011 at 10:44 PM.

  5. #5
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,320
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: Help with embedding database

    Add the library to your classpath. If you don't know what this means, I recommend doing an internet search for thses the terms. Once you have done this, write a small test program to test the database (see link above), and if you have problems post the code and any and all errors (runtime/compile time) associated with the code

  6. The Following User Says Thank You to copeg For This Useful Post:

    MrT (November 26th, 2011)

  7. #6
    Junior Member
    Join Date
    Nov 2011
    Posts
    3
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Re: Help with embedding database

    halp.jpg

    so ive gotten there but i dont know which tab to add the derby library. also i downloaded the db-derby-10.8.2.2-bin.zip file from their website but i cant find the jar files..

    Apache Derby 10.8.2.2 Release

Similar Threads

  1. Embedding Java application into external client
    By 1372586 in forum Java Networking
    Replies: 3
    Last Post: November 3rd, 2011, 08:57 AM
  2. Embedding a hyperlink within a JFrame
    By KiwiProg in forum AWT / Java Swing
    Replies: 1
    Last Post: January 3rd, 2011, 12:19 AM
  3. Database? How-To...
    By DeMolay8613 in forum JDBC & Databases
    Replies: 2
    Last Post: November 24th, 2009, 12:37 PM
  4. Embedding images in a matrix.
    By Aims_ in forum Java Theory & Questions
    Replies: 1
    Last Post: September 11th, 2009, 02:37 PM
  5. [SOLVED] Java code to embedding xml tags at start and end of file
    By John in forum File I/O & Other I/O Streams
    Replies: 3
    Last Post: April 30th, 2009, 03:02 PM