Relation.CustomFilter

Posts   
 
    
mikeg22
User
Posts: 411
Joined: 30-Jun-2005
# Posted on: 06-Apr-2006 19:12:47   

Inside PrefetchPathElement there is a Relation field which is used to identify the relation between the entity at that level of the graph and and containing entity. Every Relation object has a custom filter on it, so I would assume that the Relation field of the PrefetchPathElement would be using this custom filter, but it does not appear to. It looks like the customfilters of the FilterRelations are used, just not for the main Relation of the PrefetchPathElement.

Is there a reason for this? It would be very nice if I could customize any relation to use a filter sunglasses

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39928
Joined: 17-Aug-2003
# Posted on: 07-Apr-2006 11:09:51   

The CustomFilter is part of EntityRelation, which is the object returned by PrefetchPathElement.Relation. However the CustomFilter is used to specify additional ON clauses in a join. The Relation in a Prefetchpathelement is used to construct the subquery for parent-child fetches and it doesn't look for the customfilter at this point. It uses the FK fields and the PK fields to setup a FieldCompareSetpredicate (or multiple ones) behind the scenes.

Frans Bouma | Lead developer LLBLGen Pro