I'd vote for a new class, for the reason you give. The name could even be 
SqlMethods, as a strong hint where the class is headed (is it?).
Regards
Harald M.

-------- Original-Nachricht --------
> Datum: Fri, 4 Jan 2013 13:26:30 +0100
> Von: Oskar Berggren <[email protected]>
> An: [email protected]
> Betreff: [nhibernate-development] Support for SqlMethods.Like() in LINQ 
> queries?

> In JIRA we have the following unresolved feature requests:
> 
> NH-3301 Support SqlMethods.Like() in LINQ queries.
> NH-3302 Support for VB LINQ like operator
> 
> 
> The current state of affairs is that in e.g. 3.3.2 there is, to my
> knowledge, no way to query with patterns such as 'a%b', that is where
> the wildcard is not a suffix or prefix. I would like to improve on
> this, in 3.3.3 if possible.
> 
> 
> SqlMethods.Like() is from the System.Data.Linq.SqlClient namespace,
> i.e. Linq2SQL. This is a bit... weird... but it is available
> everywhere, and we can support it without actually adding a dependency
> to NHibernate (see code in NH-3301). A possible drawback could be the
> risk of creating an expectation that the other methods in SqlMethods
> should also be supported. The alternative I guess would be to create a
> similar method in NHibernate.Linq namespace.
> 
> Any thoughts on this?
> 
> 
> /Oskar

Reply via email to