Home  >  Forum  >  Hibernate
Post New Query

java.lang.IllegalArgumentException: Unknown name value for enum class


joined on
May 23,2013
Asked on May 25,2013
Hi Friends,

I am new to hibernate help me for below error.

Exception in thread "main" java.lang.IllegalArgumentException: Unknown name value for enum class
at org.hibernate.type.EnumType.nullSafeGet(EnumType.java:127)
at org.hibernate.type.CustomType.nullSafeGet(CustomType.java:132)
at org.hibernate.type.AbstractType.hydrate(AbstractType.java:105)
at org.hibernate.persister.entity.AbstractEntityPersister.hydrate(AbstractEntityPersister.java:2267)
at org.hibernate.loader.Loader.loadFromResultSet(Loader.java:1423)
at org.hibernate.loader.Loader.instanceNotYetLoaded(Loader.java:1351)
at org.hibernate.loader.Loader.getRow(Loader.java:1251)
at org.hibernate.loader.Loader.getRowFromResultSet(Loader.java:619)
at org.hibernate.loader.Loader.doQuery(Loader.java:745)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:270)
at org.hibernate.loader.Loader.loadCollection(Loader.java:2062)
at org.hibernate.loader.collection.CollectionLoader.initialize(CollectionLoader.java:62)
at org.hibernate.persister.collection.AbstractCollectionPersister.initialize(AbstractCollectionPersister.java:628)
at org.hibernate.event.def.DefaultInitializeCollectionEventListener.onInitializeCollection(DefaultInitializeCollectionEventListener.java:83)
at org.hibernate.impl.SessionImpl.initializeCollection(SessionImpl.java:1853)
at org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:366)
at org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCollection.java:108)
at org.hibernate.collection.PersistentMap.entrySet(PersistentMap.java:265)
joined on
May 23,2013
Replied on May 25,2013

You need to use @MapKeyEnumerated

Write Answer








Copyright ©2017 concretepage.com, all rights reserved |Privacy Policy | Contact Us