From: atirahimi (JIRA) <nh...@gm...> - 2010-12-29 05:02:55
|
filtering problem in nhibernate3 -------------------------------- Key: NH-2476 URL: http://216.121.112.228/browse/NH-2476 Project: NHibernate Issue Type: Bug Components: Core Affects Versions: 3.0.0.GA Reporter: atirahimi i've just migrated from hibernate 2.1.2 to 3 now i have a problem in one of class maps i needed a property to be conditional in this way: public class ActivePartyConditionFilter : FilterDefinition { public ActivePartyConditionFilter() { WithName("ActivePartyConditionFilter") .AddParameter("condition", NHibernate.NHibernateUtil.Int32); } } public class PartyMap : ClassMap<Party> { Schema("organizationstructure"); Id(p => p.Id); Map(p => p.IsApproved) .Not.Nullable(); Map(p => p.IsActive) .Not.Nullable(); ApplyFilter<ActivePartyConditionFilter>("IsActive = :condition"); } i've just migrated from hibernate 2.1.2 to 3 now i have a problem in one of class maps i needed a property to be conditional in this way: public class ActivePartyConditionFilter : FilterDefinition { public ActivePartyConditionFilter() { WithName("ActivePartyConditionFilter") .AddParameter("condition", NHibernate.NHibernateUtil.Int32); } } public class PartyMap : ClassMap<Party> { Schema("organizationstructure"); Id(p => p.Id); Map(p => p.IsApproved) .Not.Nullable(); Map(p => p.IsActive) .Not.Nullable(); ApplyFilter<ActivePartyConditionFilter>("IsActive = :condition"); } i didnt have any problem with this in previous version, but in this version the line ApplyFilter<ActivePartyConditionFilter>("IsActive = :condition"); would make an unusable join when it wanna execute the query -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |