After installing this module, I get a notice that "There are 30 public files attached to private nodes. Click here to make them all private."
I want to *see* which files (and the nodes they're attached to) will be affected before changing them.
I used this SQL to get the list and examine the nodes:
SELECT distinct(na.nid) FROM files f INNER JOIN upload u ON f.fid=u.fid INNER JOIN node_access na ON u.nid=na.nid WHERE na.gid != 0 AND f.filepath NOT REGEXP "private";
And it's a good thing I did. Only 2 out of the 30 listed nodes were actually private nodes.