Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- EXPLAIN EXTENDED SELECT p.posttypeid, COUNT(p.id), COUNT(c.id) FROM posts p, comments c, users u
- WHERE c.postid = p.id AND u.id = p.owneruserid AND u.reputation > 100
- AND NOT EXISTS (SELECT * FROM postlinks l WHERE l.relatedpostid = p.id)
- GROUP BY p.posttypeid;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement