[Developers] State Quarters example and "need a unique result to attach here"

John Giannandrea jg at metaweb.com
Fri Apr 4 23:57:27 UTC 2008


David Flanagan wrote:
> The other curious thing that I found is that the problem goes away if
> the state quarter object already exists--in that case it doesn't have
> problems with too many matches.

The reason you find an unambiguous match when it exists, or when doing  
a MQL read, is that you are providing one more piece of  
disambiguation: the enclosing object.   You are asking to find a thing  
called Delaware that is attached via that property and we find only one.

When doing the write for the first time, the new clause has to be  
identified globally (because you are attaching it, not creating a new  
one) and that is very similar to a toplevel query and more likely to  
find duplicates based only on name.

-jg



More information about the Developers mailing list