4

It seems that a In clause is not working properly with Linq 3.0 (trunk)

I tried following:

var l = session.Query<MyClass>.Where(p => searchGroups.Contains(p.ID)).Select(r=>r);

I get an exception that says that

the Binary operator for \"System.Collections.Generic.ICollection`1[System.Int32]\" and \"System.Int32 is not defined

With Linq 1.0 it works properly

var l = session.Linq<MyClass>.Where(p => searchGroups.Contains(p.ID)).Select(r=>r);

Should I use something different with the new Linq version or is it just a bug?

RAS
  • 8,100
  • 16
  • 64
  • 86
DennisR
  • 41
  • 2

1 Answers1

0

This is a bug.

If you want to use NHibernate.Linq, I suggest you to upgrade to NHibernate 3.2, it works like a charm.

The NHibernate 3.0 LINQ provider is a step back comparted with the previous versions...

sesispla
  • 300
  • 1
  • 4