Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

CHAPTER 26: Java DB > Creating and Using a Database

Creating and Using a Database

After packing the Java DB in a wrapper module and adding it to your NetBeans Platform application, and after you defined a dependency to the NetBeans Platform application, you can directly access the database system and create your first database. Each database is managed by Java DB in a separate directory which has the same name as the database, as shown in Figure 26-1. These directories are created in a system directory which you have to define first. An ideal location would be the user directory, for example, in which the NetBeans platform and its application-specific settings are also saved. You can get the path over the system properties so you do not need to think about independent platform paths.

This base directory becomes registered with the name derby.system.home.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free 10-Day Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint