'hibernate.dialect' must be set when no Connection available error

前端 未结 9 1751
误落风尘
误落风尘 2021-02-20 01:22

I am getting the following error when using Hibernate:

\'hibernate.dialect\' must be set when no Connection available

And I am using a datasource fo

9条回答
  •  Happy的楠姐
    2021-02-20 01:35

    The issue could be that you haven't installed the client library for the database you are trying to connect to.

    I have a Spring application that does not have a persistence.xml file and therefore no hibernate.dialect declaration.

    Once I installed the MySQL Connector/J client library the error went away.

    EDIT: I've also gotten this error when the database server wasn't running. Something that often happens now that I run my MySQL server through MAMP.

提交回复
热议问题