Prefetch Paths--Adding a tree twice?

Posts   
 
    
psandler
User
Posts: 540
Joined: 22-Feb-2005
# Posted on: 13-Apr-2005 23:18:26   

Any chance you would consider having the process that "unwraps" the prefetch paths automatically recognize when part of a tree has been added twice and automatically resolve it?

Or throw a runtime error?

Is it even possible to detect this?

We run into it a lot. simple_smile

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39933
Joined: 17-Aug-2003
# Posted on: 14-Apr-2005 09:24:30   

It's hard to detect it. The added treenodes which are added multiple times are legit for the code which fetches the data. To detect if a node is already added, I've to compare the nodes but as these are created and filled with new instances, I'm not sure if that will work. I'll see if I can add some test for this.

Frans Bouma | Lead developer LLBLGen Pro
Otis avatar
Otis
LLBLGen Pro Team
Posts: 39933
Joined: 17-Aug-2003
# Posted on: 14-Apr-2005 17:26:52   

In 1.0.2004.2 (next build of the beta), a check has been build in, which throws an exception in Add() if you add an element which defines a fetch for a property, start entity, end entity which is already added to that path object. (sub paths are different path objects).

Frans Bouma | Lead developer LLBLGen Pro
psandler
User
Posts: 540
Joined: 22-Feb-2005
# Posted on: 16-Apr-2005 14:38:31   

Otis wrote:

In 1.0.2004.2 (next build of the beta), a check has been build in, which throws an exception in Add() if you add an element which defines a fetch for a property, start entity, end entity which is already added to that path object. (sub paths are different path objects).

Nice! Thanks Frans!