Gossamer Forum
Home : Products : DBMan : Installation :

Auto record expiration

Quote Reply
Auto record expiration
Ok here's another question: Has anyone set up DBman so that records can be set to expire after a certain amount of time, and are then automatically deleted from the database? Ideally you'd set the duration for specific records in one of the database fields. If this is too complex I'll do it manually, but just in case anyone has alread done it.....

Thanks for any info.
Quote Reply
Re: Auto record expiration In reply to
Not exactly automatically, but you can set things up so you can do a "delete search" for records that fit your criteria and then have the delete come up with all the checkboxes already checked. Then you just have to click the button and they're gone. So it would be a "three-click" process -- click a link for the search, click the button to delete the records and click another link to get back to the home page or wherever you wanted to go after that.


------------------
JPD
Quote Reply
Re: Auto record expiration In reply to
That sounds like a good idea. I have am using DBMan for classified ads so it would be quite handy so you don't have to keep going through them... it'll do it for you all in one shot.


------------------
Jason
Extreme mtb
http://extreme.nas.net
Quote Reply
Re: Auto record expiration In reply to
I've written an auto-expire script that can be run fron crontab. What it does is e-mail the person sometime before their account expires so that they can renew it and if it doesn't get renewed then it automatically deletes it. It then sends them e-mail telling them their account was deleted and logs it to a file. When I find the time to work on it a bit more I'll post it here so that you guys can look over my code for bugs and give me some tips on how to possibly make it run more efficiently.