{"action":"created","comment":{"url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/comments/110520133","pull_request_review_id":31702825,"id":110520133,"diff_hunk":"@@ -9,6 +9,11 @@ objectives:\n - \"Filter and order results of a query based on aggregate functions.\"\n - \"Save a query to make a new table.\"\n - \"Apply filters to find missing values in SQL.\"\n+keypoints:\n+- \"Use the `GROUP BY` keyword to aggregate data.\"\n+- \"Functions like `MIN`, `MAX`, `AVERAGE`, `SUM`, `COUNT`, etc. operate on aggreggated data.\"\n+- \"Use the `HAVING` keyword to filter on aggregate properties.\"\n+- \"Use a `VIEW` to save a query as though it were a new table.\"","path":"_episodes/02-sql-aggregation.md","position":8,"original_position":8,"commit_id":"1e37fd605624cfac9e51112f79fe24a47682bddd","original_commit_id":"1e37fd605624cfac9e51112f79fe24a47682bddd","user":{"login":"bsmith89","id":711411,"avatar_url":"https://avatars2.githubusercontent.com/u/711411?v=3","gravatar_id":"","url":"https://api.github.com/users/bsmith89","html_url":"https://github.com/bsmith89","followers_url":"https://api.github.com/users/bsmith89/followers","following_url":"https://api.github.com/users/bsmith89/following{/other_user}","gists_url":"https://api.github.com/users/bsmith89/gists{/gist_id}","starred_url":"https://api.github.com/users/bsmith89/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bsmith89/subscriptions","organizations_url":"https://api.github.com/users/bsmith89/orgs","repos_url":"https://api.github.com/users/bsmith89/repos","events_url":"https://api.github.com/users/bsmith89/events{/privacy}","received_events_url":"https://api.github.com/users/bsmith89/received_events","type":"User","site_admin":false},"body":"@ashander How about 'Use a `VIEW` to access the result of a query as though it was a new table.'?\r\n\r\nSlightly less wordy; focuses on the access of the results rather than the saving.","created_at":"2017-04-08T14:57:02Z","updated_at":"2017-04-08T14:57:02Z","html_url":"https://github.com/datacarpentry/sql-ecology-lesson/pull/162#discussion_r110520133","pull_request_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162","_links":{"self":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/comments/110520133"},"html":{"href":"https://github.com/datacarpentry/sql-ecology-lesson/pull/162#discussion_r110520133"},"pull_request":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162"}}},"pull_request":{"url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162","id":114879991,"html_url":"https://github.com/datacarpentry/sql-ecology-lesson/pull/162","diff_url":"https://github.com/datacarpentry/sql-ecology-lesson/pull/162.diff","patch_url":"https://github.com/datacarpentry/sql-ecology-lesson/pull/162.patch","issue_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues/162","number":162,"state":"open","locked":false,"title":"Add key-points to the aggregation episode.","user":{"login":"bsmith89","id":711411,"avatar_url":"https://avatars2.githubusercontent.com/u/711411?v=3","gravatar_id":"","url":"https://api.github.com/users/bsmith89","html_url":"https://github.com/bsmith89","followers_url":"https://api.github.com/users/bsmith89/followers","following_url":"https://api.github.com/users/bsmith89/following{/other_user}","gists_url":"https://api.github.com/users/bsmith89/gists{/gist_id}","starred_url":"https://api.github.com/users/bsmith89/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bsmith89/subscriptions","organizations_url":"https://api.github.com/users/bsmith89/orgs","repos_url":"https://api.github.com/users/bsmith89/repos","events_url":"https://api.github.com/users/bsmith89/events{/privacy}","received_events_url":"https://api.github.com/users/bsmith89/received_events","type":"User","site_admin":false},"body":"Summarized some of the important functions, keywords, and concepts.\r\n\r\nReferences #129 \r\n\r\nFeedback appreciated on choice of key points.","created_at":"2017-04-07T19:02:50Z","updated_at":"2017-04-08T14:57:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6db08530e9773013dc0b984836cade03a7b2ac31","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162/commits","review_comments_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162/comments","review_comment_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/comments{/number}","comments_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues/162/comments","statuses_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/statuses/1e37fd605624cfac9e51112f79fe24a47682bddd","head":{"label":"bsmith89:patch-2","ref":"patch-2","sha":"1e37fd605624cfac9e51112f79fe24a47682bddd","user":{"login":"bsmith89","id":711411,"avatar_url":"https://avatars2.githubusercontent.com/u/711411?v=3","gravatar_id":"","url":"https://api.github.com/users/bsmith89","html_url":"https://github.com/bsmith89","followers_url":"https://api.github.com/users/bsmith89/followers","following_url":"https://api.github.com/users/bsmith89/following{/other_user}","gists_url":"https://api.github.com/users/bsmith89/gists{/gist_id}","starred_url":"https://api.github.com/users/bsmith89/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bsmith89/subscriptions","organizations_url":"https://api.github.com/users/bsmith89/orgs","repos_url":"https://api.github.com/users/bsmith89/repos","events_url":"https://api.github.com/users/bsmith89/events{/privacy}","received_events_url":"https://api.github.com/users/bsmith89/received_events","type":"User","site_admin":false},"repo":{"id":87569001,"name":"sql-ecology-lesson","full_name":"bsmith89/sql-ecology-lesson","owner":{"login":"bsmith89","id":711411,"avatar_url":"https://avatars2.githubusercontent.com/u/711411?v=3","gravatar_id":"","url":"https://api.github.com/users/bsmith89","html_url":"https://github.com/bsmith89","followers_url":"https://api.github.com/users/bsmith89/followers","following_url":"https://api.github.com/users/bsmith89/following{/other_user}","gists_url":"https://api.github.com/users/bsmith89/gists{/gist_id}","starred_url":"https://api.github.com/users/bsmith89/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bsmith89/subscriptions","organizations_url":"https://api.github.com/users/bsmith89/orgs","repos_url":"https://api.github.com/users/bsmith89/repos","events_url":"https://api.github.com/users/bsmith89/events{/privacy}","received_events_url":"https://api.github.com/users/bsmith89/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bsmith89/sql-ecology-lesson","description":"Lesson on using SQL for ecology. As of March 15, 2017 these lessons are frozen for significant changes in preparation for release.","fork":true,"url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson","forks_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/forks","keys_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/teams","hooks_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/hooks","issue_events_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/issues/events{/number}","events_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/events","assignees_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/assignees{/user}","branches_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/branches{/branch}","tags_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/tags","blobs_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/git/refs{/sha}","trees_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/statuses/{sha}","languages_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/languages","stargazers_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/stargazers","contributors_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/contributors","subscribers_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/subscribers","subscription_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/subscription","commits_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/commits{/sha}","git_commits_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/git/commits{/sha}","comments_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/comments{/number}","issue_comment_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/issues/comments{/number}","contents_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/contents/{+path}","compare_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/merges","archive_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/downloads","issues_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/issues{/number}","pulls_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/pulls{/number}","milestones_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/milestones{/number}","notifications_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/labels{/name}","releases_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/releases{/id}","deployments_url":"https://api.github.com/repos/bsmith89/sql-ecology-lesson/deployments","created_at":"2017-04-07T17:09:52Z","updated_at":"2017-04-07T17:09:54Z","pushed_at":"2017-04-07T19:01:59Z","git_url":"git://github.com/bsmith89/sql-ecology-lesson.git","ssh_url":"git@github.com:bsmith89/sql-ecology-lesson.git","clone_url":"https://github.com/bsmith89/sql-ecology-lesson.git","svn_url":"https://github.com/bsmith89/sql-ecology-lesson","homepage":"http://datacarpentry.github.io/sql-ecology-lesson","size":1842,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"gh-pages"}},"base":{"label":"datacarpentry:gh-pages","ref":"gh-pages","sha":"e559805b61bffbdf7895c437e00393ce5270b64a","user":{"login":"datacarpentry","id":6666450,"avatar_url":"https://avatars1.githubusercontent.com/u/6666450?v=3","gravatar_id":"","url":"https://api.github.com/users/datacarpentry","html_url":"https://github.com/datacarpentry","followers_url":"https://api.github.com/users/datacarpentry/followers","following_url":"https://api.github.com/users/datacarpentry/following{/other_user}","gists_url":"https://api.github.com/users/datacarpentry/gists{/gist_id}","starred_url":"https://api.github.com/users/datacarpentry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/datacarpentry/subscriptions","organizations_url":"https://api.github.com/users/datacarpentry/orgs","repos_url":"https://api.github.com/users/datacarpentry/repos","events_url":"https://api.github.com/users/datacarpentry/events{/privacy}","received_events_url":"https://api.github.com/users/datacarpentry/received_events","type":"Organization","site_admin":false},"repo":{"id":30597605,"name":"sql-ecology-lesson","full_name":"datacarpentry/sql-ecology-lesson","owner":{"login":"datacarpentry","id":6666450,"avatar_url":"https://avatars1.githubusercontent.com/u/6666450?v=3","gravatar_id":"","url":"https://api.github.com/users/datacarpentry","html_url":"https://github.com/datacarpentry","followers_url":"https://api.github.com/users/datacarpentry/followers","following_url":"https://api.github.com/users/datacarpentry/following{/other_user}","gists_url":"https://api.github.com/users/datacarpentry/gists{/gist_id}","starred_url":"https://api.github.com/users/datacarpentry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/datacarpentry/subscriptions","organizations_url":"https://api.github.com/users/datacarpentry/orgs","repos_url":"https://api.github.com/users/datacarpentry/repos","events_url":"https://api.github.com/users/datacarpentry/events{/privacy}","received_events_url":"https://api.github.com/users/datacarpentry/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/datacarpentry/sql-ecology-lesson","description":"Lesson on using SQL for ecology. As of March 15, 2017 these lessons are frozen for significant changes in preparation for release.","fork":false,"url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson","forks_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/forks","keys_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/keys{/key_id}","collaborators_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/teams","hooks_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/hooks","issue_events_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues/events{/number}","events_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/events","assignees_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/assignees{/user}","branches_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/branches{/branch}","tags_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/tags","blobs_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/git/refs{/sha}","trees_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/git/trees{/sha}","statuses_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/statuses/{sha}","languages_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/languages","stargazers_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/stargazers","contributors_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/contributors","subscribers_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/subscribers","subscription_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/subscription","commits_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/commits{/sha}","git_commits_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/git/commits{/sha}","comments_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/comments{/number}","issue_comment_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues/comments{/number}","contents_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/contents/{+path}","compare_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/compare/{base}...{head}","merges_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/merges","archive_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/downloads","issues_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues{/number}","pulls_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls{/number}","milestones_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/milestones{/number}","notifications_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/labels{/name}","releases_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/releases{/id}","deployments_url":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/deployments","created_at":"2015-02-10T15:07:29Z","updated_at":"2017-04-06T11:58:31Z","pushed_at":"2017-04-07T23:02:31Z","git_url":"git://github.com/datacarpentry/sql-ecology-lesson.git","ssh_url":"git@github.com:datacarpentry/sql-ecology-lesson.git","clone_url":"https://github.com/datacarpentry/sql-ecology-lesson.git","svn_url":"https://github.com/datacarpentry/sql-ecology-lesson","homepage":"http://datacarpentry.github.io/sql-ecology-lesson","size":1840,"stargazers_count":11,"watchers_count":11,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":56,"mirror_url":null,"open_issues_count":23,"forks":56,"open_issues":23,"watchers":11,"default_branch":"gh-pages"}},"_links":{"self":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162"},"html":{"href":"https://github.com/datacarpentry/sql-ecology-lesson/pull/162"},"issue":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues/162"},"comments":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/issues/162/comments"},"review_comments":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162/comments"},"review_comment":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/pulls/162/commits"},"statuses":{"href":"https://api.github.com/repos/datacarpentry/sql-ecology-lesson/statuses/1e37fd605624cfac9e51112f79fe24a47682bddd"}}}}
{"actor":{"display_login":"bsmith89"}}