[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-4026) one-to-one non-lazy loading but Filters Not Applied.

Sandeep Vaid (JIRA) noreply at atlassian.com
Mon Apr 5 01:41:32 EDT 2010


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-4026?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=36125#action_36125 ] 

Sandeep Vaid commented on HHH-4026:
-----------------------------------

Steve,
      Firstly i am sorry if my questions have troubled you.. My intention was just to help hibernate to improve. Regarding our previous communications, you have replied regarding changing cardinality but you have not yet replied to this query. It's fine with me if you don't want to reply but it would be great if you can redirect me to someone else from hibernate team with whom i can discuss this point in more detail as till today this question is open for me. 

> one-to-one non-lazy loading but Filters Not Applied.
> ----------------------------------------------------
>
>                 Key: HHH-4026
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-4026
>             Project: Hibernate Core
>          Issue Type: Patch
>          Components: core
>    Affects Versions: 3.2.6, 3.2.7, 3.3.0.CR1, 3.3.0.CR2, 3.3.0.GA, 3.3.0.SP1, 3.3.1, 3.3.2
>         Environment: Hibernate 3.2.6
>            Reporter: Sandeep Vaid
>            Assignee: Steve Ebersole
>         Attachments: EntityJoinWalker.java
>
>
> While fetching one-to-one association, filters are not applied.
> I have modified the hibernate code to resolve this issue. With these changes, if filters a are enabled for one-to-one associations,
> they will be applied (appear in sql) else not.
> Changes Done:
>  A) In EntityJoinWalker.java >> constructor:line 40
>     Current Code:
>      StringBuffer whereCondition = whereString( getAlias(), uniqueKey, batchSize )
>      			//include the discriminator and class-level where, but not filters
> 			.append( persister.filterFragment( getAlias(), Collections.EMPTY_MAP ) );
> 			
>    Changed Code: 
>     	StringBuffer whereCondition = whereString( getAlias(), uniqueKey, batchSize );
>    			//include the discriminator and class-level where, but not filters
>         String filter= persister.filterFragment( getAlias(), enabledFilters);
>         whereCondition.insert( 0, StringHelper.moveAndToBeginning(filter) );

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list