These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: net.sf.hibernate.PropertyValueException
PostPosted: Thu Dec 02, 2004 5:18 pm 
Beginner
Beginner

Joined: Fri Mar 12, 2004 5:18 pm
Posts: 44
Hi,

i am trying to update the adminapp 0.92 example to Hibernate 2.1.7.

In the original admin app 0.92, it funs fine when I try to create a user. but when I upgrade to 2.1.7, I get the following exception:

Can someon please help me understand the exception. I step thru the code, it trying to save() user. And the user object is NOT null.


00:55:37,437 ERROR HibernateInterceptor:42 - HibernateException in execute()
net.sf.hibernate.PropertyValueException: not-null property references a null or transient value: org.hibernate.admin.model.User.timeOfLastUpdate

Hibernate version: 2.1.7

Mapping documents: the one from adminapp 0.9.2 example

Code between sessionFactory.openSession() and session.close():

Full stack trace of any exception that occurs:

00:55:37,437 ERROR HibernateInterceptor:42 - HibernateException in execute()
net.sf.hibernate.PropertyValueException: not-null property references a null or transient value: org.hibernate.admin.model.User.timeOfLastUpdate
at net.sf.hibernate.impl.SessionImpl.checkNullability(SessionImpl.java:1286)
at net.sf.hibernate.impl.SessionImpl.doSave(SessionImpl.java:937)
at net.sf.hibernate.impl.SessionImpl.doSave(SessionImpl.java:866)
at net.sf.hibernate.impl.SessionImpl.saveWithGeneratedIdentifier(SessionImpl.java:788)
at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:747)
at org.hibernate.admin.action.CreateUserAction.go(CreateUserAction.java:31)
at org.hibernate.admin.action.AbstractAction.execute(AbstractAction.java:41)

Name and version of the database you are using:

My SQL 4.1.17

The generated SQL (show_sql=true):

Debug level Hibernate log excerpt:


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.