Expand my Community achievements bar.

Data is getting lost after saving composite multifield content fragments

Avatar

Level 3

Hi,

 

Data is getting lost after saving composite multifield content fragments

 

when we save the composite multifield the data is getting stored in JSON object and after some time if we open the content fragment the data is lost. If we go to crxde and check on the node the value was stored in a string array and the previous JSON object stored was deleted.

 

we have written the custom JS with the help of the below link

 

https://experience-aem.blogspot.com/2023/06/aem-cloud-service-multiple-composite-multifields-in-cont...

 

 

Please help me on the same what might the issue. 

 

Thanks & Regards,

Kalyan

2 Replies

Avatar

Community Advisor

Hi @kalyanchakravarthych 

I have faced this issue with multifield. When the multifield is storing data as an array in CRX it cannot retrieve as like as we have submitted the data. When add multifield item, we are adding the items as like a node. So when retrieve the data it should be as like as node. But in CRX it's storing like an array that's why it's cannot retrieve the data.

 

If the saved multifield data is look like this then the multifield can retrieve the data correctly.

AsifChowdhury_0-1704245937918.png

 

 

Thanks

Hi @AsifChowdhury ,


we are using the old approach as the data will get stored as a JSON. This issue is not occurring frequently. Sometimes only this issue occurring still we couldnot replicate the issue in our local. Only higher environments we are facing this issue sometimes. Not able to get when the issue is occurring and what might be causing this issue. Please help me is there any workaround for this time being 

 

 

Thanks & Regards,

Kalyan