troubleshooting Question

Deleting (cffile) files where the related id does not exist- Coldfusion

Avatar of izweig
izweig asked on
ColdFusion LanguageMySQL Server
9 Comments1 Solution424 ViewsLast Modified:
I need help figuring out how to delete files in a folder that are no longer needed.
They are image files, which relate to active real estate listings.
When the listing is no longer active I wish to delete this images which are associated to the listing.
My database table only has active listings, it doesn't not have old, deleted or expired.
When my table gets updated (every 20 min) any non actives will be purged from the table, when this occurs I want to be able to delete the associated images from the server..

the naming convention is:
property id = propertyID
Images = IMG_propertyID_1, IMG_propertyID_2, IMG_propertyID_3...

Any help with this would be greatly appreciated.
Join our community to see this answer!
Unlock 1 Answer and 9 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros