Skip to main content



      Home
Home » Modeling » EMF » [CDO] Collection returns contains = false for Query loaded object.
[CDO] Collection returns contains = false for Query loaded object. [message #1387016] Mon, 23 June 2014 09:45 Go to next message
Eclipse UserFriend
Hi,

We experience this strange thing, that collection.contains(Object) =>
false, when the Object was retrieved with a Query. How do we force the
loading of the object on the collection? When debugging the collection,
the collection.contains(Object) => true, as the debug/variable view will
read the object and it will be resolved (I suspect this).

Is this a known issue, how do I force loading a collection when we
obtain objects from a query?

Thank You,
Christophe
Re: [CDO] Collection returns contains = false for Query loaded object. [message #1387017 is a reply to message #1387016] Mon, 23 June 2014 09:48 Go to previous messageGo to next message
Eclipse UserFriend
Actually, even better would be if we can execute query delete statements
with CDO, which would enable us to skip the part which does the contain
check.

On 23-06-14 15:45, Christophe Bouhier wrote:
> Hi,
>
> We experience this strange thing, that collection.contains(Object) =>
> false, when the Object was retrieved with a Query. How do we force the
> loading of the object on the collection? When debugging the collection,
> the collection.contains(Object) => true, as the debug/variable view will
> read the object and it will be resolved (I suspect this).
>
> Is this a known issue, how do I force loading a collection when we
> obtain objects from a query?
>
> Thank You,
> Christophe
Re: [CDO] Collection returns contains = false for Query loaded object. [message #1387020 is a reply to message #1387017] Mon, 23 June 2014 09:57 Go to previous message
Eclipse UserFriend
We solved it by not doing a contains(), but just calling remove([CDO
query loaded object]), which works.

=> Soooo, to conclude ".contains([SQL obtained object]) considered
harmfull with CDO!"


On 23-06-14 15:48, Christophe Bouhier wrote:
> Actually, even better would be if we can execute query delete statements
> with CDO, which would enable us to skip the part which does the contain
> check.
>
> On 23-06-14 15:45, Christophe Bouhier wrote:
>> Hi,
>>
>> We experience this strange thing, that collection.contains(Object) =>
>> false, when the Object was retrieved with a Query. How do we force the
>> loading of the object on the collection? When debugging the collection,
>> the collection.contains(Object) => true, as the debug/variable view will
>> read the object and it will be resolved (I suspect this).
>>
>> Is this a known issue, how do I force loading a collection when we
>> obtain objects from a query?
>>
>> Thank You,
>> Christophe
>
>
>
Previous Topic:[EMF databinding] bind specific element in an EList by index
Next Topic:Custom validation for ID attribute
Goto Forum:
  


Current Time: Thu Apr 24 17:26:37 EDT 2025

Powered by FUDForum. Page generated in 0.03038 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top