Start a new topic

Why don't all users see the same data when querying?

When I perform a query in my app, it is only returning objects created by the current user. How can I get everybody's data to return with a query?
1 Comment

Every entity in a collection has a JSON field called `_acl`, which stands for Access Control List. By default, every entity is only modifiable and accessible by the user who created it.



To get around this, you can modify the _acl fields when saving your entities.



First, add an _acl declaration to your GenericJson class:



@Key("_acl")

private KinveyMetaData.AccessControlList acl;





Then, before you save this entity you can call various methods on that acl field, such as:



acl = new KinveyMetaData.AccessControlList();

acl.setGloballyReadable(true);

acl.setGloballyWriteable(true);

Login or Signup to post a comment