-->
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.  [ 3 posts ] 
Author Message
 Post subject: joda-time, @Temporal & hibernate 3.2.0
PostPosted: Mon Aug 28, 2006 10:08 am 
Newbie

Joined: Wed Nov 09, 2005 5:28 am
Posts: 3
i'm using
- Hibernate Core 3.2.0.cr2
- Hibernate Annotations 3.2.0.cr1
- joda-time-1.3

and the following annotations:
Code:
@Temporal(TemporalType.TIMESTAMP)
@Column(name = "start_date_time")
@Type (type = "org.joda.time.contrib.hibernate.PersistentDateTime")
private DateTime _startDateTime;


and I'm getting the following exception
Code:
org.hibernate.AnnotationException: @Temporal should be set on a java.util.Date or java.util.Calendar property: xxx.xxx.xxx.CallImpl._startDateTime
at org.hibernate.cfg.annotations.SimpleValueBinder.setType(SimpleValueBinder.java:88)


is this restriction for the @Temporal annotation really neccessary?! .. any known workarounds?

P.S. same code works fine with hibernate 3.0 & 3.1 libs

many thx in advance,
prot


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 28, 2006 10:13 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
Since you setup the @Type already, @Temporal is misplaced. @Temporal is some kind of a @Type but standard for java.util.Date, just get rid of it

_________________
Emmanuel


Top
 Profile  
 
 Post subject: Re: joda-time, @Temporal & hibernate 3.2.0
PostPosted: Sat Aug 28, 2010 1:44 am 
Newbie

Joined: Sat Aug 28, 2010 1:41 am
Posts: 1
http://skhanzada.wordpress.com/2010/07/ ... notations/


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

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.