[ http://216.121.112.228/browse/NH-1930?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=21152#action_21152 ]
Ricardo Peres commented on NH-1930:
-----------------------------------
Same happens when specifying a where clause on a set using fetch mode join.
I think the restriction should be placed on the join on clause, not the global where.
> Filter condition on nullable many to one should be on the join, not the where
> -----------------------------------------------------------------------------
>
> Key: NH-1930
> URL: http://216.121.112.228/browse/NH-1930
> Project: NHibernate
> Issue Type: Bug
> Components: Core
> Affects Versions: 2.1.0.GA
> Reporter: Ayende Rahien
> Assignee: Ayende Rahien
> Priority: Major
>
> Using the code in NH-1919, get produces the following values for nullable property that has a filter on it:
> SELECT invoice0_.id AS id1_1_,
> invoice0_.otherprop AS otherprop1_1_,
> invoice0_.categoryid AS categoryid1_1_,
> category1_.id AS id0_0_,
> category1_.validuntil AS validuntil0_0_
> FROM invoice invoice0_
> LEFT OUTER JOIN category category1_
> ON invoice0_.categoryid = category1_.id
> WHERE category1_.validuntil > @p0
> AND invoice0_.id = @p1
> The problem is that the filter should be applied on the join, not on the where, since it filter the parent as well as the child.
--
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
|