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
I had this problem too. The reason was missing <property name="dataSource" ref="dataSource" />
element in <bean id="sessionFactory">
definition.
I had the same errors.
My problem was that I put the hibernate.properties
under one package
instead of the src
.
So my solution to my problem was moving hibernate.properties
from package
to src
.
In some cases just using a wrong name for the database results in this Exception. Hibernate is apparently trying to determine the dialect before doing anything else, and as the DB cannot be reached, the error message comes from the part responsible for the dialect select. Bad error messaging on part of Hibernate.