Find all posts and replies that have images inserted/attached

Related to:

https://meta.discourse.org/t/don-t-see-uploaded-images-404ing-and-uploads-tar-gz-does-not-show-them/93429

Title says it all: Is it possible to list all posts and responses that have images associated with it?

3 Likes

Hmm this is a good point @zogstrip do we have an advanced search operator for “post has at least one image”? That could be quite handy if it’s not nightmarishly difficult to implement.

2 Likes

I think that now you’d need the data Explorer plugin and search raw for upload://

Edit: But I wasn’t even close.

I think the post_uploads table carries this relation.

4 Likes

Yup, we have “with:images” which is generic and “filetype:jpg” which looks for a specific upload extension.

4 Likes

Can I do a OR?

“with:images filetype:jpg OR filetype:jpeg”

https://comments.alittlebitofspice.com/search?q=with%3Aimages%20filetype%3Ajpg%20OR%20filetype%3Ajpeg

You can join the file types with a comma to achieve an OR, i.e.

with:images filetype:jpg,jpeg

https://comments.alittlebitofspice.com/search?q=with%3Aimages%20filetype%3Ajpg%2Cjpeg

4 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.