Skip to content

Instantly share code, notes, and snippets.

@rxnlabs
Created April 8, 2015 15:18
Show Gist options
  • Save rxnlabs/805b2fcea3634fd5a867 to your computer and use it in GitHub Desktop.
Save rxnlabs/805b2fcea3634fd5a867 to your computer and use it in GitHub Desktop.
MySQL - DR Get the websites that Disqus users visit who also comment on the DR
SELECT disqus_forum_users.forum_id, COUNT(disqus_forum_users.forum_id) AS `count`, disqus_forums.description, website FROM disqus_forum_users LEFT JOIN disqus_forums ON disqus_forums.forum_id = disqus_forum_users.forum_id WHERE disqus_forum_users.forum_id != "dailyreckoning" GROUP BY forum_id ORDER BY count DESC;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment