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

  • Home
  • SEARCH
  • 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 7041431
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T02:02:42+00:00 2026-05-28T02:02:42+00:00

I created a maven project in eclipse Helios and added hibernate-search 4.0.0.Final and mysql-connector-java

  • 0

I created a maven project in eclipse Helios and added “hibernate-search 4.0.0.Final” and “mysql-connector-java 5.1.18” to pom.xml dependencies. Both downloaded and exist in .m2 directory. but when I run this code:

Session session = HibernateUtil.getSessionFactory().openSession();
session.beginTransaction();
session.getTransaction().commit();

just to create tables in DB to import previously provided values in tables, I get the following error:

Exception in thread "main" java.lang.ExceptionInInitializerError
    at net.leemoo.test.HibernateUtil.buildSessionFactory(HibernateUtil.java:19)
    at net.leemoo.test.HibernateUtil.<clinit>(HibernateUtil.java:8)
    at net.leemoo.test.MainClass.main(MainClass.java:9)
Caused by: org.hibernate.HibernateException: Dialect class not found: jdbc:mysql://localhost:3306/test?createDatabaseIfNotExist=true&useUnicode=true&characterEncoding=utf-8
    at org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl.constructDialect(DialectFactoryImpl.java:76)
    at org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl.buildDialect(DialectFactoryImpl.java:64)
    at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:166)
    at org.hibernate.service.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:75)
    at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:159)
    at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:131)
    at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:71)
    at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2270)
    at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2266)
    at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1735)
    at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1775)
    at net.leemoo.test.HibernateUtil.buildSessionFactory(HibernateUtil.java:13)
    ... 2 more
Caused by: org.hibernate.service.classloading.spi.ClassLoadingException: Unable to load class [jdbc:mysql://localhost:3306/test?createDatabaseIfNotExist=true&useUnicode=true&characterEncoding=utf-8]
    at org.hibernate.service.classloading.internal.ClassLoaderServiceImpl.classForName(ClassLoaderServiceImpl.java:141)
    at org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl.constructDialect(DialectFactoryImpl.java:73)
    ... 13 more
Caused by: java.lang.ClassNotFoundException: Could not load requested class : jdbc:mysql://localhost:3306/test?createDatabaseIfNotExist=true&useUnicode=true&characterEncoding=utf-8
    at org.hibernate.service.classloading.internal.ClassLoaderServiceImpl$1.findClass(ClassLoaderServiceImpl.java:99)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at org.hibernate.service.classloading.internal.ClassLoaderServiceImpl.classForName(ClassLoaderServiceImpl.java:138)
    ... 14 more

I don’t know what to do? I googled this error but no success. plz help me. thanks in advance.

  • 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-28T02:02:43+00:00Added an answer on May 28, 2026 at 2:02 am

    It looks like something (or someone) has put the JDBC URL in a property that is suppose to contain a class name.

    Caused by: java.lang.ClassNotFoundException: 
        Could not load requested class : 
        jdbc:mysql://localhost:3306/test?createDatabaseIfNotExist=true&useUnicode=true&characterEncoding=utf-8
    

    That is not a class name, and is should be.

    Check your configuration properties …

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

Sidebar

Related Questions

I've created a project in eclipse and added maven dependencies. In Eclipse, it says
I installed Eclipse Helios and m2eclipse. Next I created a maven project. Now Eclipse
I have created a Java Maven Build Hibernate 2.0 Application with Eclipse. I want
From reading A Java web project created with Maven is not recognized as such
I am creating a project using maven with spring and hibernate. I added a
I created a GWT app project using the gwt-maven-plugin and added the same to
I created a Maven project in Eclipse using the webapp artifact and put the
I have created a Maven project and I want to add all Maven dependencies
I create a Maven project in Eclipse Helios. It works fine for a day,
I have commited just the src folder and pom.xml of maven project into SVN

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.