-->
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.  [ 2 posts ] 
Author Message
 Post subject: Question relating Hibernate Search Date/Time problem?
PostPosted: Fri Jan 08, 2010 5:25 pm 
Newbie

Joined: Fri Jan 08, 2010 5:14 pm
Posts: 1
Hello dear,
I am working with Hibernate search which stores data in Derby, and uses Lucene for query.
there is one field creationTime which is of TIMESTAMP type in Database and in mapping class its type is java.util.Date.
here is the declaration of that field in mapping class
/////////////////////////////////////////////////////////////////
@Field(index = Index.UN_TOKENIZED, store=Store.NO)
@DateBridge(resolution=Resolution.MINUTE)
private Date creationTime;
//////////////////////////////////////////////////////////////////

when I store the value in this field the value goes exactly what I want. but if I look in the index the value of time stored is 1 hour behind the value i sent. more if I query the time with the exact which I stored nothing comes. but if I query the time 1 hour before, it returns me the exact time (actually which is 1 hour after the queried or actually the time which is stored in DB).
Is there any bug in my logic or this is by default behaviour of Hibernate?????? do I have to search in exactly this fashion or can I do proper search (I mean if I query exact value that is stored in DB the result should be positive)?????


thanx in advance

regards


Top
 Profile  
 
 Post subject: Re: Question relating Hibernate Search Date/Time problem?
PostPosted: Tue May 18, 2010 5:00 pm 
Hibernate Team
Hibernate Team

Joined: Fri Oct 05, 2007 4:47 pm
Posts: 2536
Location: Third rock from the Sun
I'm sorry for the late answer, we from the Search team don't notice all posts on the wrong forum. Hibernate Search related questions should be posted on the Search forum.

If you still need help, please post to the correct forum.
Hibernate Search encodes times in GMT timezone, your query should match that.

_________________
Sanne
http://in.relation.to/


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.