Reputation: 3
I'm using Backand as my BaaS and I’m looking for a quick way to delete entries I no longer need. In the data model I created, I have an object called “Auctions”, in this object I want to add an action that delete the entries that surpassed the end time of the auction.
I’ve been looking in the server-side actions and I didn’t find a quick way to do it.
Thanks
Upvotes: 0
Views: 38
Reputation: 76
There are 2 approaches for this issue:
The downside for the first approach is that there will be gaps in times between the scheduled deletion that those entries will still exist.
I recommend the second approach, let me know if you are interested in the first and I will send instructions.
For the second, you need to go to the security tab of the object with the relevant entries. In there you can set a predefined filter either with SQL or NoSQL that will always filter expired entries. This will act as if those entries do not exist for every GET request.
Upvotes: 0