{"action":"created","comment":{"url":"https://api.github.com/repos/apache/spark/pulls/comments/111685668","pull_request_review_id":32945727,"id":111685668,"diff_hunk":"@@ -232,7 +232,9 @@ case class AlterTableSetPropertiesCommand(\n     val table = catalog.getTableMetadata(tableName)\n     DDLUtils.verifyAlterTableType(catalog, table, isView)\n     // This overrides old properties\n-    val newTable = table.copy(properties = table.properties ++ properties)\n+    val newTable = table.copy(\n+      properties = table.properties ++ properties,\n+      comment = properties.get(\"comment\"))","path":"sql/core/src/main/scala/org/apache/spark/sql/execution/command/ddl.scala","position":7,"original_position":7,"commit_id":"1db31031d86f2d674242bba567a7c9101577f46a","original_commit_id":"1db31031d86f2d674242bba567a7c9101577f46a","user":{"login":"wzhfy","id":10878553,"avatar_url":"https://avatars0.githubusercontent.com/u/10878553?v=3","gravatar_id":"","url":"https://api.github.com/users/wzhfy","html_url":"https://github.com/wzhfy","followers_url":"https://api.github.com/users/wzhfy/followers","following_url":"https://api.github.com/users/wzhfy/following{/other_user}","gists_url":"https://api.github.com/users/wzhfy/gists{/gist_id}","starred_url":"https://api.github.com/users/wzhfy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wzhfy/subscriptions","organizations_url":"https://api.github.com/users/wzhfy/orgs","repos_url":"https://api.github.com/users/wzhfy/repos","events_url":"https://api.github.com/users/wzhfy/events{/privacy}","received_events_url":"https://api.github.com/users/wzhfy/received_events","type":"User","site_admin":false},"body":"add some comment to explain why this is necessary?","created_at":"2017-04-16T15:00:34Z","updated_at":"2017-04-16T15:00:34Z","html_url":"https://github.com/apache/spark/pull/17649#discussion_r111685668","pull_request_url":"https://api.github.com/repos/apache/spark/pulls/17649","_links":{"self":{"href":"https://api.github.com/repos/apache/spark/pulls/comments/111685668"},"html":{"href":"https://github.com/apache/spark/pull/17649#discussion_r111685668"},"pull_request":{"href":"https://api.github.com/repos/apache/spark/pulls/17649"}}},"pull_request":{"url":"https://api.github.com/repos/apache/spark/pulls/17649","id":116057284,"html_url":"https://github.com/apache/spark/pull/17649","diff_url":"https://github.com/apache/spark/pull/17649.diff","patch_url":"https://github.com/apache/spark/pull/17649.patch","issue_url":"https://api.github.com/repos/apache/spark/issues/17649","number":17649,"state":"open","locked":false,"title":"[SPARK-20023][SQL][follow up] Output table comment for DESC FORMATTED after adding/modifying table comment using Alter TableSetPropertiesCommand","user":{"login":"sujith71955","id":12999161,"avatar_url":"https://avatars2.githubusercontent.com/u/12999161?v=3","gravatar_id":"","url":"https://api.github.com/users/sujith71955","html_url":"https://github.com/sujith71955","followers_url":"https://api.github.com/users/sujith71955/followers","following_url":"https://api.github.com/users/sujith71955/following{/other_user}","gists_url":"https://api.github.com/users/sujith71955/gists{/gist_id}","starred_url":"https://api.github.com/users/sujith71955/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sujith71955/subscriptions","organizations_url":"https://api.github.com/users/sujith71955/orgs","repos_url":"https://api.github.com/users/sujith71955/repos","events_url":"https://api.github.com/users/sujith71955/events{/privacy}","received_events_url":"https://api.github.com/users/sujith71955/received_events","type":"User","site_admin":false},"body":"### What changes were proposed in this pull request?\r\nThis PR is a follow up PR to **JIRA issue 20023** where table comment was not displayed in describe formatted command after user creates a table with table comment.But still issue exists  when user alter    the table properties  and adds/updates table comment. table comment which is now directly  part of CatalogTable  instance is not getting updated and  old table comment was shown,  to handle this issue   while updating the table properties map with newly added/modified properties  in CatalogTable \r\ninstance also update the comment parameter in CatalogTable with the newly added/modified comment.\r\n\r\n### How was this patch tested?\r\nAdded test cases  as part of **SQLQueryTestSuite** for verifying  table comment using desc formatted table query after adding or modifying table comment as part of **AlterTableSetPropertiesCommand**.","created_at":"2017-04-16T12:12:30Z","updated_at":"2017-04-16T15:00:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7929eaae01cf861f4613a984cc5584a2b8e36dc7","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/apache/spark/pulls/17649/commits","review_comments_url":"https://api.github.com/repos/apache/spark/pulls/17649/comments","review_comment_url":"https://api.github.com/repos/apache/spark/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/spark/issues/17649/comments","statuses_url":"https://api.github.com/repos/apache/spark/statuses/1db31031d86f2d674242bba567a7c9101577f46a","head":{"label":"sujith71955:alter_table_comment","ref":"alter_table_comment","sha":"1db31031d86f2d674242bba567a7c9101577f46a","user":{"login":"sujith71955","id":12999161,"avatar_url":"https://avatars2.githubusercontent.com/u/12999161?v=3","gravatar_id":"","url":"https://api.github.com/users/sujith71955","html_url":"https://github.com/sujith71955","followers_url":"https://api.github.com/users/sujith71955/followers","following_url":"https://api.github.com/users/sujith71955/following{/other_user}","gists_url":"https://api.github.com/users/sujith71955/gists{/gist_id}","starred_url":"https://api.github.com/users/sujith71955/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sujith71955/subscriptions","organizations_url":"https://api.github.com/users/sujith71955/orgs","repos_url":"https://api.github.com/users/sujith71955/repos","events_url":"https://api.github.com/users/sujith71955/events{/privacy}","received_events_url":"https://api.github.com/users/sujith71955/received_events","type":"User","site_admin":false},"repo":{"id":79292929,"name":"spark","full_name":"sujith71955/spark","owner":{"login":"sujith71955","id":12999161,"avatar_url":"https://avatars2.githubusercontent.com/u/12999161?v=3","gravatar_id":"","url":"https://api.github.com/users/sujith71955","html_url":"https://github.com/sujith71955","followers_url":"https://api.github.com/users/sujith71955/followers","following_url":"https://api.github.com/users/sujith71955/following{/other_user}","gists_url":"https://api.github.com/users/sujith71955/gists{/gist_id}","starred_url":"https://api.github.com/users/sujith71955/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sujith71955/subscriptions","organizations_url":"https://api.github.com/users/sujith71955/orgs","repos_url":"https://api.github.com/users/sujith71955/repos","events_url":"https://api.github.com/users/sujith71955/events{/privacy}","received_events_url":"https://api.github.com/users/sujith71955/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/sujith71955/spark","description":"Mirror of Apache Spark","fork":true,"url":"https://api.github.com/repos/sujith71955/spark","forks_url":"https://api.github.com/repos/sujith71955/spark/forks","keys_url":"https://api.github.com/repos/sujith71955/spark/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sujith71955/spark/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sujith71955/spark/teams","hooks_url":"https://api.github.com/repos/sujith71955/spark/hooks","issue_events_url":"https://api.github.com/repos/sujith71955/spark/issues/events{/number}","events_url":"https://api.github.com/repos/sujith71955/spark/events","assignees_url":"https://api.github.com/repos/sujith71955/spark/assignees{/user}","branches_url":"https://api.github.com/repos/sujith71955/spark/branches{/branch}","tags_url":"https://api.github.com/repos/sujith71955/spark/tags","blobs_url":"https://api.github.com/repos/sujith71955/spark/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sujith71955/spark/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sujith71955/spark/git/refs{/sha}","trees_url":"https://api.github.com/repos/sujith71955/spark/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sujith71955/spark/statuses/{sha}","languages_url":"https://api.github.com/repos/sujith71955/spark/languages","stargazers_url":"https://api.github.com/repos/sujith71955/spark/stargazers","contributors_url":"https://api.github.com/repos/sujith71955/spark/contributors","subscribers_url":"https://api.github.com/repos/sujith71955/spark/subscribers","subscription_url":"https://api.github.com/repos/sujith71955/spark/subscription","commits_url":"https://api.github.com/repos/sujith71955/spark/commits{/sha}","git_commits_url":"https://api.github.com/repos/sujith71955/spark/git/commits{/sha}","comments_url":"https://api.github.com/repos/sujith71955/spark/comments{/number}","issue_comment_url":"https://api.github.com/repos/sujith71955/spark/issues/comments{/number}","contents_url":"https://api.github.com/repos/sujith71955/spark/contents/{+path}","compare_url":"https://api.github.com/repos/sujith71955/spark/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sujith71955/spark/merges","archive_url":"https://api.github.com/repos/sujith71955/spark/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sujith71955/spark/downloads","issues_url":"https://api.github.com/repos/sujith71955/spark/issues{/number}","pulls_url":"https://api.github.com/repos/sujith71955/spark/pulls{/number}","milestones_url":"https://api.github.com/repos/sujith71955/spark/milestones{/number}","notifications_url":"https://api.github.com/repos/sujith71955/spark/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sujith71955/spark/labels{/name}","releases_url":"https://api.github.com/repos/sujith71955/spark/releases{/id}","deployments_url":"https://api.github.com/repos/sujith71955/spark/deployments","created_at":"2017-01-18T01:59:05Z","updated_at":"2017-01-18T01:59:31Z","pushed_at":"2017-04-16T12:09:52Z","git_url":"git://github.com/sujith71955/spark.git","ssh_url":"git@github.com:sujith71955/spark.git","clone_url":"https://github.com/sujith71955/spark.git","svn_url":"https://github.com/sujith71955/spark","homepage":null,"size":270677,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"e090f3c0ceebdf341536a1c0c70c80afddf2ee2a","user":{"login":"apache","id":47359,"avatar_url":"https://avatars3.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":17165658,"name":"spark","full_name":"apache/spark","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars3.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/spark","description":"Mirror of Apache Spark","fork":false,"url":"https://api.github.com/repos/apache/spark","forks_url":"https://api.github.com/repos/apache/spark/forks","keys_url":"https://api.github.com/repos/apache/spark/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/spark/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/spark/teams","hooks_url":"https://api.github.com/repos/apache/spark/hooks","issue_events_url":"https://api.github.com/repos/apache/spark/issues/events{/number}","events_url":"https://api.github.com/repos/apache/spark/events","assignees_url":"https://api.github.com/repos/apache/spark/assignees{/user}","branches_url":"https://api.github.com/repos/apache/spark/branches{/branch}","tags_url":"https://api.github.com/repos/apache/spark/tags","blobs_url":"https://api.github.com/repos/apache/spark/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/spark/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/spark/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/spark/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/spark/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/spark/languages","stargazers_url":"https://api.github.com/repos/apache/spark/stargazers","contributors_url":"https://api.github.com/repos/apache/spark/contributors","subscribers_url":"https://api.github.com/repos/apache/spark/subscribers","subscription_url":"https://api.github.com/repos/apache/spark/subscription","commits_url":"https://api.github.com/repos/apache/spark/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/spark/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/spark/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/spark/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/spark/contents/{+path}","compare_url":"https://api.github.com/repos/apache/spark/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/spark/merges","archive_url":"https://api.github.com/repos/apache/spark/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/spark/downloads","issues_url":"https://api.github.com/repos/apache/spark/issues{/number}","pulls_url":"https://api.github.com/repos/apache/spark/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/spark/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/spark/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/spark/labels{/name}","releases_url":"https://api.github.com/repos/apache/spark/releases{/id}","deployments_url":"https://api.github.com/repos/apache/spark/deployments","created_at":"2014-02-25T08:00:08Z","updated_at":"2017-04-16T14:19:33Z","pushed_at":"2017-04-16T14:05:59Z","git_url":"git://github.com/apache/spark.git","ssh_url":"git@github.com:apache/spark.git","clone_url":"https://github.com/apache/spark.git","svn_url":"https://github.com/apache/spark","homepage":null,"size":271460,"stargazers_count":12455,"watchers_count":12455,"language":"Scala","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":11707,"mirror_url":"git://git.apache.org/spark.git","open_issues_count":472,"forks":11707,"open_issues":472,"watchers":12455,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/spark/pulls/17649"},"html":{"href":"https://github.com/apache/spark/pull/17649"},"issue":{"href":"https://api.github.com/repos/apache/spark/issues/17649"},"comments":{"href":"https://api.github.com/repos/apache/spark/issues/17649/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/spark/pulls/17649/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/spark/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/spark/pulls/17649/commits"},"statuses":{"href":"https://api.github.com/repos/apache/spark/statuses/1db31031d86f2d674242bba567a7c9101577f46a"}}}}
{"actor":{"display_login":"wzhfy"}}