Skip to content

Instantly share code, notes, and snippets.

@maxwell
Created January 19, 2011 02:45
Show Gist options
  • Save maxwell/785599 to your computer and use it in GitHub Desktop.
Save maxwell/785599 to your computer and use it in GitHub Desktop.
StatusMessage Load (1.6ms) SELECT DISTINCT `posts`.* FROM `posts` INNER JOIN `post_visibilities` ON `posts`.`id` = `post_visibilities`.`post_id` INNER JOIN `aspects` ON `aspects`.`id` = `post_visibilities`.`aspect_id` WHERE (`posts`.`type` = 'StatusMessage') AND (`posts`.`pending` = 0) AND (`aspects`.`id` IN (3, 4)) ORDER BY created_at DESC LIMIT 15 OFFSET 0
SQL (0.4ms) SELECT COUNT(DISTINCT `contacts`.`id`) FROM `contacts` LEFT OUTER JOIN `people` ON `people`.`id` = `contacts`.`person_id` WHERE (`contacts`.user_id = 2) AND (`contacts`.`pending` = 0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment