--
You received this message because you are subscribed to the Google Groups "nhusers" group.
To post to this group, send email to nhu...@googlegroups.com.
To unsubscribe from this group, send email to nhusers+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/nhusers?hl=en.
(Not sure if it will need a custom extension to handle it).
I've assigned it to me, but I'm not sure if we can easily fix it (I'll have
a chew on it and see if I can come up with anything).
You can use HQL ... this translates to the & operator in SQL Server, however
I don't think this is cross-platform because someone has noted in the
comments here that Oracle uses the function bitand():
http://216.121.112.228/browse/NH-1192
You could also try the LINQ provider (.Query<>) since it may generate the
same HQL syntax and hopefully the same SQL as the HQL parser.
I suspect that the longer-term solution to this may be to add a new function
to the Dialect (e.g., bitand) and then implement the 'correct' syntax in
each inherited dialect (there doesn't seem to be an SQL standard for this
unfortunately).
In the meantime, if you are determined to get this working with QueryOver, I
think your best bet is to create a custom SQL Server function and use that.
You can register a custom extension method to make the syntax nicer ... for
an example have a look at the RestrictionsExtensions here:
http://nhibernate.svn.sourceforge.net/viewvc/nhibernate/trunk/nhibernate/src/NHibernate/Criterion/RestrictionsExtensions.cs?revision=5837&view=markup
.. and the ExpressionProcessor.RegisterCustomMethodCall() method.
Hope that helps.
Richard