-->
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: Query Generator for Custom Types/Mapping
PostPosted: Fri Jan 23, 2009 3:34 am 
Beginner
Beginner

Joined: Wed Jun 09, 2004 8:10 am
Posts: 28
Is it possible to change query which is being generated for custom type/mapping?

Like I have 2 date fields which work as a partial date structure, sql query generated by NHibernate is not valid.

It generates:

DATE_FROM >= p0 AND DATE_TO >= p1

I need:

DATE_FROM <= p1 AND DATE_TO >= p0

Another option is to use string and process it with custom query.
Yet another option is to create custom user type in database (not sure whether NHibernate supports this).

But I think I would have to handle this in the .Net code or avoid using NHibernate for this entity. :(


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.