How to update database?

Hi, I am building an app, and I’m trying to update my database automatically, I have a collection that includes inside of it a Date&Hour property, and what I’m trying to do is to delete that record when the date in this property (Date&Hour property) is expired.
for example, if the date in some record is 19/03/2022, I want that when the date turns to 20/03/2022 to delete this record automatically .
how I can do this in Adalo?

Hi Deaa,

Welcome to the community :partying_face:

Add a countdown timer to a screen and make it a list and connect it to the collection where the Date&Hour property stored. Then add a filter that Date&Hour is before Start of Today. And add how many seconds in the countdown to 1 and add Delete current item action in the countdown on the Actions section countdown finished actions and you can make that countdown invisible.

And you can add visibility condition to the list as Only Visible when All Items ( the collection name )>Count>is greater than>0. And add a filter to the count that Date&Hour property> is before> Start of Today.

I think you can use API here too!

Thank you

thank you very much for your help, I will try it.