29
Views
10
Comments
Solved
Mobile Data-Syncronization
Question

Hello, i have a problem with my mobile application, i have some Local Entities and when i try to add the default Sync-Data Actions it only lets me do the read-only actions, and i don't understand why it only let me the other sync-data option too.

2021-06-02 20-50-04
Márcio Carvalho
Solution

Its because you are trying to create a local entity on an entity that is exposed only as read-only

On your entity in the CS module I think that's where you have the entity, please put the expose read-only as NO! and then refresh!


UserImage.jpg
chandresh vikram singh patel

Hi,

Please do right click on the LocalStorageEntity there you will find the read write action as well

Screenshot 2022-05-24 124617.png
UserImage.jpg
Adolfo Rodriguez Martinez

As you can see on the screenshot, i can only use the read-only action

2021-07-14 10-21-07
Krunal Vyas

Do you want to store orders from order to validate entity?

UserImage.jpg
Adolfo Rodriguez Martinez

I just want to know how i can use the read/write action on that entity

2021-07-14 10-21-07
Krunal Vyas

Have you created those entities from actual entities.

If yes then make sure you not created from static entities.

Because in static entities it only gives read only actions.

UserImage.jpg
Adolfo Rodriguez Martinez

Yeah, i created them from actual entities, but those entities aren't static entities, so my problem is not relationated with that.

2021-06-02 20-50-04
Márcio Carvalho

"This option is only available if the local entity is linked to the database entity (with the Id as a foreign key to the database entity). That happens if you create local entities with a right-click on Local Storage and choose Add Entity from Database...."

https://success.outsystems.com/Documentation/11/Developing_an_Application/Use_Data/Offline/Offline_Data_Sync_Patterns/Read/Write_Data_Last_Write_Wins

Can you share an OML?

Kind Regards,

Márcio

UserImage.jpg
Adolfo Rodriguez Martinez

I have the entity created as you said, with the Id as a foreign key of the entity on the database, but it still only let me use the read-only action.

2021-06-02 20-50-04
Márcio Carvalho
Solution

Its because you are trying to create a local entity on an entity that is exposed only as read-only

On your entity in the CS module I think that's where you have the entity, please put the expose read-only as NO! and then refresh!


UserImage.jpg
Adolfo Rodriguez Martinez

You got the solution, thank you so much and have a good day!

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.