Forum Academy Marketplace Showcase Pricing Features

Delete an object that is referenced from another object

If I delete an object that is referenced from a field on another object, the reference is still preserved. This means I get a reference to a non-existing object. Example:

I have a data type called Organization. It has a field called Members which is a list of Users.

Organization A has one member. I now delete this user. If I search for Organizations where “Members is empty”, Organization A does not show up, because it still has a reference to the user. If I query using the GET API, I also still get the id of the user.

Is this a bug? It’s very inconvenient if you have to manually detect all references to make sure you clean up when you delete something. I cannot really see the use case where you want to preserve the reference to a deleted object…

[EDIT 27. January 2017 - this has now been fixed. Great :slight_smile: ]


It’s a (bad) design decision. On our list to clean up, though it involves enough changes to how the delete functionality works that it may be a while before we get around to it.

1 Like

Is there some way to localize this elements if it’s not possible to search for “field” empty?


Great that you are aware of this. It really requires a lot of discipline to make sure to clean up correctly (in addition to a lot of extra expensive “Search for” actions to remove an item from a list before it’s deleted).

Do you think that all this mean that a deleted object from a list still occupy his spot in the 10000 maximum objects per list count?

This topic was automatically closed after 14 days. New replies are no longer allowed.