From: NHibernate J. <mik...@us...> - 2007-03-05 10:36:36
|
[ http://jira.nhibernate.org/browse/NH-933?page=3Dcomments#action_1520= 3 ] =20 Taavi K=C3=B5osaar commented on NH-933: ---------------------------------- Furthermore i seem to get an exception "Cannot use collections with InExpre= ssion"), when trying to give an array of items into the Expression.In(). Looking at the code, i see this: if (criteriaQuery.GetTypeUsingProjection(criteria, this._propertyName).IsCo= llectionType) { throw new QueryException("Cannot use collections with InExpression"); } The method seem to allow the collection type, but at the same it throws exc= eption when you try to send in an collection (array). Id say this is more serious bug. > Expression.In does not support Generic lists > -------------------------------------------- > > Key: NH-933 > URL: http://jira.nhibernate.org/browse/NH-933 > Project: NHibernate > Type: Bug > Components: Core > Versions: 1.2.0.CR1 > Reporter: Taavi K=C3=B5osaar > Priority: Trivial > Fix For: 1.2.0.GA > > Expression.In takes only ICollection, but since generic lists come from I= Collection<T>, not from ICollection, it is not possible to put in generic l= ists.=20 > Perhaps a quick solution is to use IEnumerable as input type (IList<T> im= plements this inetrface, and so do most of the collection/array/List types)= ? > I did not find this to be reported anywhere. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |