Attachments missing from some records in feature service

522
2
05-17-2023 02:40 PM
MelissaWalker
Occasional Contributor

Hi, I have opened a few of my hosted feature services and found that some of the records which previously had photos attached are now showing as no attachments. The records which only had a photo (no other fields captured) seem to be the ones affected. Has anyone else had this issue and is it possible to recover the lost attachments? Thanks in advance.

Missing attachments.JPG

0 Kudos
2 Replies
MobiusSnake
MVP Regular Contributor

I've lost attachments on a couple of occasions but it's mostly been due to a faulty script of some kind.

One case was straightforward - I was downloading images, manipulating them, then replacing them by deleting the original and posting the manipulated image.  The delete worked but the replacement didn't.

The other case was a script that was creating a view; found out the hard way that you can inadvertently destroy not just one but all of your attachments if your view definition JSON is incorrect.  I don't think that's the case here though, since you still have some attachments.

The only other similar thing I've come across was when a user with editing privileges was deleting attachments unbeknownst to me.  Any possibility something like that is happening?

Unfortunately I'm fairly certain there are no ways to recover attachments unless you've already built a backup process around your service.

0 Kudos
MelissaWalker
Occasional Contributor

Thanks. I haven't been modifying the images or records, only viewing them. And I am certain that none of the other editors would be deleting photos. The Editor and Edit date fields do not show changes that would account for the missing photos (not sure if these record cahnges to attachments though?). I also haven't created any view layers. Ironically, all the services I have made backups of appear to be  fine, but there are a couple I had not downloaded yet and these are the ones with missing photos.

0 Kudos