recovering JavaDB sample database

34 views
Skip to first unread message

Natalya Portnov

unread,
Feb 20, 2016, 10:48:21 PM2/20/16
to JPassion.com: Java EE 6 and 7 Programming
Accidentally deleted JavaDB Sample database. 
Tried to reinstall NetBeans with JavaEE modules and reinstalled glassfish but cannot get it back.
Now I manually create tables & data for each exercise but it makes it slow to move through the Java EE programming Labs.
Please help with detailed instructions on how to recover the sample database.

Thank you,
Natalya

Sang Shin

unread,
Feb 21, 2016, 5:43:08 AM2/21/16
to natalya...@gmail.com, JPassion.com: Java EE 6 and 7 Programming
Can you tell us which JavaDB sample database are you referring to?

-Sang


Thank you,
Natalya
--
You received this message because you are subscribed to the Google Groups "JPassion.com: Java EE 6 and 7 Programming" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jpassion_javae...@googlegroups.com.
Visit this group at https://groups.google.com/group/jpassion_javaee6.
For more options, visit https://groups.google.com/d/optout.

-- 
-------------------------------------------------------------------
             Sang Shin, sangshi...@gmail.com
  President and Chief Instructor of JPassion.com (JavaPassion.com)
         http://www.linkedin.com/in/javapassion (Linkedin)
          http://twitter.com/javapassion (Tweeter)
            Life is worth living... with Passion!
    
   Practically Free 3 to 5 days Live, Hands-on, Online Codecamps on
 Java,Spring,Hadoop,HTML5,Ruby/Rails,Grails,JavaScript/jQuery,Android
             http://jpassion.com/codecamps       
----------------------------------------------------------------------

Richard Grin

unread,
Feb 21, 2016, 8:00:38 AM2/21/16
to jpassion...@googlegroups.com
Hi Natalya,

Perhaps this link http://code.metager.de/source/xref/netbeans/derby/etc/sample.sql will help you (temporarily out of order at this time): it contains a script to create a new sample database.

Another way: when you install NetBeans again, you delete first (before the installation) the directory of the database in .netbeans.derby.

This link can be helpful too: https://netbeans.org/bugzilla/show_bug.cgi?id=248822.

Richard

Natalya Portnov

unread,
Feb 23, 2016, 7:54:05 AM2/23/16
to Sang Shin, JPassion.com: Java EE 6 and 7 Programming
Still no answer. Maybe because I Replied instead of Replying to All.
Trying again:

It is used through exercises in Java EEProgramming/JPA Query Lab.
There is a note copied/pasted below in Java EEProgramming/JPA Query Lab but that did NOT work for me.

 Trouble-shooting:  If you don't see the MANUFACTURER nor PRODUCT_CODE tables, it is beause the samples database has not been installed with the Java DB. (If you have downloaded and installed "NetBeans with Java EE modules", the samples database should have been installed automatically.)  Now, what you can do is to install "Database" module to the NetBeans and it should install "samples" database.

Sang Shin

unread,
Feb 23, 2016, 8:36:13 AM2/23/16
to Natalya Portnov, JPassion.com: Java EE 6 and 7 Programming


On 2/23/2016 7:53 AM, Natalya Portnov wrote:
Still no answer. Maybe because I Replied instead of Replying to All.
Trying again:

Did you see the response from Richard on this?  He mentioned
the following link

  http://code.metager.de/source/xref/netbeans/derby/etc/sample.sql

You can run samples.sql mentioned above to create sample tables.

-S


Natalya Portnov

unread,
Feb 23, 2016, 7:46:10 PM2/23/16
to JPassion.com: Java EE 6 and 7 Programming, natalya...@gmail.com
Great! Thank you for your help!
Reply all
Reply to author
Forward
0 new messages