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 7940403
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T23:22:45+00:00 2026-06-03T23:22:45+00:00

I want to use an H2 database in my Java project, but unfortunately I

  • 0

I want to use an H2 database in my Java project, but unfortunately I can’t use any external .jar or .class files. (It’s a build system out of my control and I can only submit source files to it, stupid as that is.) So I thought to simply download the H2 Java sources and add all these Java packages and Java files directly into my project source folder.

However, after doing so I get several build errors in Eclipse for some of the Java files in the H2 code base. For example, the file “org.h2.jdbc.JdbcStatement” has the following errors: “The type JdbcStatement must implement the inherited abstract method Wrapper.unwrap(Class)”. There are also several other errors as well.

So my question is: how can or should I properly add the H2 source files into my Java project?

  • 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-06-03T23:22:46+00:00Added an answer on June 3, 2026 at 11:22 pm

    The sources jar file of H2 is available in the Maven repository, as described in the download section of the docs. The current version is:

    http://repo2.maven.org/maven2/com/h2database/h2/1.3.166/h2-1.3.166-sources.jar

    You may have to “switch” the source code of H2 to the target Java version however. (This is required because the source code can’t at the same time be used for Java 5 and for Java 6 – as an example the JDBC API in Java 6 has to support the method ResultSet.updateNClob(int columnIndex, NClob x), but the interface NClob is not available in Java 5.) This is the reason why you get the exception “The type JdbcStatement must implement the inherited abstract method Wrapper.unwrap(Class)”.

    To switch the source code, you can use the build script of H2, or you can use find / replace yourself: to enable Java 6, replace the string /*## Java 1.6 ## with //## Java 1.6 ## in the source code.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am a java programmer and I want to use MongoDB in my project.
I've got collection of objects I want use in my custom tag.But I can
I want to use SQLite as a database for my C++ project. I also
I want to use Neo4j database and JRuby on Rails to build a new
I want to use Access database with query for pivot table in Excel. How
Proviso: I don't want to use a database for the following, please. I'm getting
First, I don't want to use a database or a local file. Is it
I want to use JDBC to access a MySQL database. What or will an
I want to use string similarity functions to find corrupted data in my database.
I created a new mysql database and i want to use foreign keys 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.