The following snippet lists the pages/post and the templates they are using
SELECT ID, post_title, meta_key , meta_value, post_date, post_status
FROM `wp_postmeta`, wp_posts
WHERE `meta_key` LIKE '_wp_page_template' AND post_id=ID
Disclaimer: The content in this post is for educational purposes only. Always remember to take a backup before doing any of the suggested steps just to be on the safe side.
Referral Note: When you purchase through a referral link (if any) on this page, we may earn a commission.
If you're feeling thankful, you can buy me a coffee or a beer