Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 456235
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T22:27:03+00:00 2026-05-12T22:27:03+00:00

For unit tests, demonstrations and Hibernate tasks I would like to use a small

  • 0

For unit tests, demonstrations and Hibernate tasks I would like to use a small and simple Java database like Derby / Java DB or HSQLDB, which can be called from within Maven.

So far I have not found a Maven plugin which can download and launch Java DB (which is my favorite at the moment) or something similar.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T22:27:04+00:00Added an answer on May 12, 2026 at 10:27 pm

    An simple setup for unit tests is to start hsqldb in memory:

    db.connection.driver_class=org.hsqldb.jdbcDriver
    db.connection.url=jdbc:hsqldb:mem:aname
    db.connection.username=sa
    db.connection.password=
    hibernate.dialect=org.hibernate.dialect.HSQLDialect
    

    No start and stop needed. The JDBC driver will “start” the database.

    You could use that for demonstrations, too. If you’re initializing the database while the applications starts.

    The database setup can be done with hibernate.hbm2ddl.auto.


    Edit by kdgregory:

    To have Maven include HSQLDB in the dependencies for the test phase only, use this in your POM:

    <dependency>
        <groupId>hsqldb</groupId>
        <artifactId>hsqldb</artifactId>
        <version>1.8.0.7</version>
        <scope>test</scope>
    </dependency>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My unit tests use Hibernate to connect to an in-memory HSQLDB database. I was
For unit tests I would like to mimic different commandline arguments. How do I
For managing unit tests in Visual Studio, I use the Test List Editor. There's
I´m looking for a unit tests framework for database development. I´m currently developing for
I'm writing unit tests using nose , and I'd like to check whether a
I have unit tests which contains asians chars (chineses ideograms), but Eclipse just display
I'm writing unit tests for stored procedures in VSTE for Database Professionals, and want
I am writing (junit) unit tests for a class which implements an exposed interface
Unit tests are cheaper to write and maintain, but they don't cover all scenarios.
One of our unit tests is to populate properties within our business objects with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.