SQL
AخA
use commonswiki_p;
SELECT CONCAT("https://commons.wikimedia.org/wiki/File:", img_name ) 'link', img_timestamp 'upload date'
FROM image
JOIN page p1
ON p1.page_namespace = 6
AND p1.page_title = img_name
JOIN categorylinks
ON cl_from = page_id
AND cl_type = "file"
AND cl_to = "User_page_images"
LEFT JOIN globalimagelinks
ON gil_to = img_name
LEFT join imagelinks
ON il_to = img_name
left join page p2 on il_from = p2.page_id and p2.page_title not like 'OgreBot/%'
WHERE gil_to IS NULL and p2.page_id is NULL
ORDER BY img_timestamp desc;
By running queries you agree to the Cloud Services Terms of Use and you irrevocably agree to release your SQL under CC0 License.
All SQL code is licensed under CC0 License.