Highlighted

Duplicate rows in DataGrid in Flex3/LCDS2.5

Avatar

Avatar

olegkon

Avatar

olegkon

olegkon

13-11-2008

Hi,



My project in Flex2/LCDS2 uses DataGrid very extensively with
streaming data coming in.

After we recompiled it with Flex3 and run with LCDS2.5, we
see a strange behavior:

originally it shows everything right, but all coming data
creates duplicate rows.

As soon as we do sort on any column, duplicates disappear.

But then again new data creates duplicate rows...



We have never seen that happening with Flex2,

in fact it's running fine in production for a few months.



Has anybody seen such behavior ?

How can we cure that ?

(we do not do any special processing on that data, so I
really doubt it's anything in our code)

(using Java 1.5 on the server).



Any help is very appreciated.



Thank you in advance,

Oleg.





Replies

Highlighted

Avatar

Avatar

alice_data

Avatar

alice_data

alice_data

17-11-2008

Hi,



I think I am having a similar experience too, although I am
using Flex 3. I have just posted my question a few minutes ago.
Does this sound like yours?



Alice
Highlighted

Avatar

Avatar

olegkon

Avatar

olegkon

olegkon

17-11-2008

Alice,



At least from your description I don't see how our problems
are related.

I do not use PHP or HTTPService, but Flex2 DataGrid
collections, LCDS & Java on backend.

Please explain in more details if you disagree.



Thanks,

Oleg.

Highlighted

Avatar

Avatar

alice_data

Avatar

alice_data

alice_data

17-11-2008

Hi,



Maybe you are right. The nature of our problem may be a
little different, but I also see duplicate rows being generated
when they are not supposed to be according to my back-end coding
and they get displayed on my DataGrid just as you described above.
I even tried to echo back the variables I passed to the HTTPService
request, and they bring back the way they should be instead of all
the entries.



I am experiencing some problems myself that I cannot explain
from what I see from my DataGrid, since those rows get generated
only through Flex, but they don't when I just run it from PHP.



Perhaps you might be able to tell me how I could solve my
problem here?



Alice
Highlighted

Avatar

Avatar

Karl_Sigiscar_1

Avatar

Karl_Sigiscar_1

Karl_Sigiscar_1

18-11-2008



Hi,



I did have this problem.



The only solution I could find is to :



1. Create a new collection as the data provider for the
datagrid. Don't assign directly the collection coming from the
server



2. Define a <Binding> tag in order to detect changes to
the collection and set the destination to a setter function



3. In the setter, reset the dataprovider collection, go
through each element in the incoming collection from the server,
check if the element is already present in the dataprovider
collection based on the entity key and add it if not present.





Highlighted

Avatar

Avatar

Nirvish_Patel

Avatar

Nirvish_Patel

Nirvish_Patel

19-11-2008

Hi Olegkon,



I an facing same problem like you.

If you had solved this problem then please let me know.



I will appreciate your hlep.



Thank you in advance,

Nirvish
Highlighted

Avatar

Avatar

Nirvish_Patel

Avatar

Nirvish_Patel

Nirvish_Patel

19-11-2008

Hi Karl_Sigiscar_1971 ,



Could you please give me code how you implement your code to
resove the problem?



i will apperciate your help.



Thanks,

Nirvish
Highlighted

Avatar

Avatar

olegkon

Avatar

olegkon

olegkon

19-11-2008

Guys,



We haven't resolved that problem, just planning to open a
ticket with Adobe.

In the logs we can see that 1 row is inserted (from data
stream) on Java side, and 2 identical rows are inserted in
ArrayCollection on Flex side.



Could you please specify with which version of LCDS you have
this problem ? That is important.

As for us, it worked fine until we started using 2.6.0 with
Flex3

(I was just told that it was OK with Flex2 on LCDS2.5.1 and
Java5.0).

With LCDS 2.6.1 still have a problem.



What's your story?



Thank you,

Oleg.
Highlighted

Avatar

Avatar

Nirvish_Patel

Avatar

Nirvish_Patel

Nirvish_Patel

19-11-2008

Hi Guys
Highlighted

Avatar

Avatar

Nirvish_Patel

Avatar

Nirvish_Patel

Nirvish_Patel

19-11-2008

Hi,



I am also facing problem for LCDS2.6.0 with Flex3.

It is working properly in Flex2 on LCDS2.5.1 and Java5.0



Thanks,

Nirvish