{"action":"created","comment":{"url":"https://api.github.com/repos/facebook/presto/pulls/comments/48223776","id":48223776,"diff_hunk":"@@ -283,7 +284,7 @@ private HiveRecordWriter createWriter(List<Object> partitionRow)\n         checkArgument(partitionRow.size() == partitionColumnNames.size(), \"size of partitionRow is different from partitionColumnNames\");\n \n         List<String> partitionValues = partitionRow.stream()\n-                .map(Object::toString) // todo this seems wrong\n+                .map(Objects::toString)","path":"presto-hive/src/main/java/com/facebook/presto/hive/HivePageSink.java","position":13,"original_position":13,"commit_id":"40ea56edc35e3128203784624223d35c2219f92c","original_commit_id":"40ea56edc35e3128203784624223d35c2219f92c","user":{"login":"harunurhan","id":4868667,"avatar_url":"https://avatars.githubusercontent.com/u/4868667?v=3","gravatar_id":"","url":"https://api.github.com/users/harunurhan","html_url":"https://github.com/harunurhan","followers_url":"https://api.github.com/users/harunurhan/followers","following_url":"https://api.github.com/users/harunurhan/following{/other_user}","gists_url":"https://api.github.com/users/harunurhan/gists{/gist_id}","starred_url":"https://api.github.com/users/harunurhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harunurhan/subscriptions","organizations_url":"https://api.github.com/users/harunurhan/orgs","repos_url":"https://api.github.com/users/harunurhan/repos","events_url":"https://api.github.com/users/harunurhan/events{/privacy}","received_events_url":"https://api.github.com/users/harunurhan/received_events","type":"User","site_admin":false},"body":"@dain I couldn't find a way to represent hive's NULL as a string in Presto. If it should be done as @yuananf suggested, I can change it to\r\n~~~\r\n.map(partitionValue -> partitionValue == null ? \r\n               HIVE_DEFAULT_DYNAMIC_PARTITION : partitionValue.toString())\r\n~~~\r\n\r\nHowever it does not seem right to me since we are dealing with values not keys.","created_at":"2015-12-22T05:49:23Z","updated_at":"2015-12-22T05:49:23Z","html_url":"https://github.com/facebook/presto/pull/4217#discussion_r48223776","pull_request_url":"https://api.github.com/repos/facebook/presto/pulls/4217","_links":{"self":{"href":"https://api.github.com/repos/facebook/presto/pulls/comments/48223776"},"html":{"href":"https://github.com/facebook/presto/pull/4217#discussion_r48223776"},"pull_request":{"href":"https://api.github.com/repos/facebook/presto/pulls/4217"}}},"pull_request":{"url":"https://api.github.com/repos/facebook/presto/pulls/4217","id":54290890,"html_url":"https://github.com/facebook/presto/pull/4217","diff_url":"https://github.com/facebook/presto/pull/4217.diff","patch_url":"https://github.com/facebook/presto/pull/4217.patch","issue_url":"https://api.github.com/repos/facebook/presto/issues/4217","number":4217,"state":"open","locked":false,"title":"Fix NPE when inserting new record with null partition key","user":{"login":"harunurhan","id":4868667,"avatar_url":"https://avatars.githubusercontent.com/u/4868667?v=3","gravatar_id":"","url":"https://api.github.com/users/harunurhan","html_url":"https://github.com/harunurhan","followers_url":"https://api.github.com/users/harunurhan/followers","following_url":"https://api.github.com/users/harunurhan/following{/other_user}","gists_url":"https://api.github.com/users/harunurhan/gists{/gist_id}","starred_url":"https://api.github.com/users/harunurhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harunurhan/subscriptions","organizations_url":"https://api.github.com/users/harunurhan/orgs","repos_url":"https://api.github.com/users/harunurhan/repos","events_url":"https://api.github.com/users/harunurhan/events{/privacy}","received_events_url":"https://api.github.com/users/harunurhan/received_events","type":"User","site_admin":false},"body":"Suggested fix for issues #3860 and #4122. ","created_at":"2015-12-21T19:05:11Z","updated_at":"2015-12-22T05:49:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e63c365aa677de79bfd1ac929e27c1f5355f177d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/facebook/presto/pulls/4217/commits","review_comments_url":"https://api.github.com/repos/facebook/presto/pulls/4217/comments","review_comment_url":"https://api.github.com/repos/facebook/presto/pulls/comments{/number}","comments_url":"https://api.github.com/repos/facebook/presto/issues/4217/comments","statuses_url":"https://api.github.com/repos/facebook/presto/statuses/40ea56edc35e3128203784624223d35c2219f92c","head":{"label":"harunurhan:fix3860","ref":"fix3860","sha":"40ea56edc35e3128203784624223d35c2219f92c","user":{"login":"harunurhan","id":4868667,"avatar_url":"https://avatars.githubusercontent.com/u/4868667?v=3","gravatar_id":"","url":"https://api.github.com/users/harunurhan","html_url":"https://github.com/harunurhan","followers_url":"https://api.github.com/users/harunurhan/followers","following_url":"https://api.github.com/users/harunurhan/following{/other_user}","gists_url":"https://api.github.com/users/harunurhan/gists{/gist_id}","starred_url":"https://api.github.com/users/harunurhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harunurhan/subscriptions","organizations_url":"https://api.github.com/users/harunurhan/orgs","repos_url":"https://api.github.com/users/harunurhan/repos","events_url":"https://api.github.com/users/harunurhan/events{/privacy}","received_events_url":"https://api.github.com/users/harunurhan/received_events","type":"User","site_admin":false},"repo":{"id":40881623,"name":"presto","full_name":"harunurhan/presto","owner":{"login":"harunurhan","id":4868667,"avatar_url":"https://avatars.githubusercontent.com/u/4868667?v=3","gravatar_id":"","url":"https://api.github.com/users/harunurhan","html_url":"https://github.com/harunurhan","followers_url":"https://api.github.com/users/harunurhan/followers","following_url":"https://api.github.com/users/harunurhan/following{/other_user}","gists_url":"https://api.github.com/users/harunurhan/gists{/gist_id}","starred_url":"https://api.github.com/users/harunurhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harunurhan/subscriptions","organizations_url":"https://api.github.com/users/harunurhan/orgs","repos_url":"https://api.github.com/users/harunurhan/repos","events_url":"https://api.github.com/users/harunurhan/events{/privacy}","received_events_url":"https://api.github.com/users/harunurhan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/harunurhan/presto","description":"Distributed SQL query engine for running interactive analytic queries against big data sources.","fork":true,"url":"https://api.github.com/repos/harunurhan/presto","forks_url":"https://api.github.com/repos/harunurhan/presto/forks","keys_url":"https://api.github.com/repos/harunurhan/presto/keys{/key_id}","collaborators_url":"https://api.github.com/repos/harunurhan/presto/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/harunurhan/presto/teams","hooks_url":"https://api.github.com/repos/harunurhan/presto/hooks","issue_events_url":"https://api.github.com/repos/harunurhan/presto/issues/events{/number}","events_url":"https://api.github.com/repos/harunurhan/presto/events","assignees_url":"https://api.github.com/repos/harunurhan/presto/assignees{/user}","branches_url":"https://api.github.com/repos/harunurhan/presto/branches{/branch}","tags_url":"https://api.github.com/repos/harunurhan/presto/tags","blobs_url":"https://api.github.com/repos/harunurhan/presto/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/harunurhan/presto/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/harunurhan/presto/git/refs{/sha}","trees_url":"https://api.github.com/repos/harunurhan/presto/git/trees{/sha}","statuses_url":"https://api.github.com/repos/harunurhan/presto/statuses/{sha}","languages_url":"https://api.github.com/repos/harunurhan/presto/languages","stargazers_url":"https://api.github.com/repos/harunurhan/presto/stargazers","contributors_url":"https://api.github.com/repos/harunurhan/presto/contributors","subscribers_url":"https://api.github.com/repos/harunurhan/presto/subscribers","subscription_url":"https://api.github.com/repos/harunurhan/presto/subscription","commits_url":"https://api.github.com/repos/harunurhan/presto/commits{/sha}","git_commits_url":"https://api.github.com/repos/harunurhan/presto/git/commits{/sha}","comments_url":"https://api.github.com/repos/harunurhan/presto/comments{/number}","issue_comment_url":"https://api.github.com/repos/harunurhan/presto/issues/comments{/number}","contents_url":"https://api.github.com/repos/harunurhan/presto/contents/{+path}","compare_url":"https://api.github.com/repos/harunurhan/presto/compare/{base}...{head}","merges_url":"https://api.github.com/repos/harunurhan/presto/merges","archive_url":"https://api.github.com/repos/harunurhan/presto/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/harunurhan/presto/downloads","issues_url":"https://api.github.com/repos/harunurhan/presto/issues{/number}","pulls_url":"https://api.github.com/repos/harunurhan/presto/pulls{/number}","milestones_url":"https://api.github.com/repos/harunurhan/presto/milestones{/number}","notifications_url":"https://api.github.com/repos/harunurhan/presto/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/harunurhan/presto/labels{/name}","releases_url":"https://api.github.com/repos/harunurhan/presto/releases{/id}","created_at":"2015-08-17T09:27:40Z","updated_at":"2015-08-17T09:27:49Z","pushed_at":"2015-12-21T19:04:03Z","git_url":"git://github.com/harunurhan/presto.git","ssh_url":"git@github.com:harunurhan/presto.git","clone_url":"https://github.com/harunurhan/presto.git","svn_url":"https://github.com/harunurhan/presto","homepage":"https://prestodb.io","size":52503,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"facebook:master","ref":"master","sha":"a7d83509b7ac9b2d01e0d70341be768c74c1e090","user":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"repo":{"id":5349565,"name":"presto","full_name":"facebook/presto","owner":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/facebook/presto","description":"Distributed SQL query engine for running interactive analytic queries against big data sources.","fork":false,"url":"https://api.github.com/repos/facebook/presto","forks_url":"https://api.github.com/repos/facebook/presto/forks","keys_url":"https://api.github.com/repos/facebook/presto/keys{/key_id}","collaborators_url":"https://api.github.com/repos/facebook/presto/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/facebook/presto/teams","hooks_url":"https://api.github.com/repos/facebook/presto/hooks","issue_events_url":"https://api.github.com/repos/facebook/presto/issues/events{/number}","events_url":"https://api.github.com/repos/facebook/presto/events","assignees_url":"https://api.github.com/repos/facebook/presto/assignees{/user}","branches_url":"https://api.github.com/repos/facebook/presto/branches{/branch}","tags_url":"https://api.github.com/repos/facebook/presto/tags","blobs_url":"https://api.github.com/repos/facebook/presto/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/facebook/presto/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/facebook/presto/git/refs{/sha}","trees_url":"https://api.github.com/repos/facebook/presto/git/trees{/sha}","statuses_url":"https://api.github.com/repos/facebook/presto/statuses/{sha}","languages_url":"https://api.github.com/repos/facebook/presto/languages","stargazers_url":"https://api.github.com/repos/facebook/presto/stargazers","contributors_url":"https://api.github.com/repos/facebook/presto/contributors","subscribers_url":"https://api.github.com/repos/facebook/presto/subscribers","subscription_url":"https://api.github.com/repos/facebook/presto/subscription","commits_url":"https://api.github.com/repos/facebook/presto/commits{/sha}","git_commits_url":"https://api.github.com/repos/facebook/presto/git/commits{/sha}","comments_url":"https://api.github.com/repos/facebook/presto/comments{/number}","issue_comment_url":"https://api.github.com/repos/facebook/presto/issues/comments{/number}","contents_url":"https://api.github.com/repos/facebook/presto/contents/{+path}","compare_url":"https://api.github.com/repos/facebook/presto/compare/{base}...{head}","merges_url":"https://api.github.com/repos/facebook/presto/merges","archive_url":"https://api.github.com/repos/facebook/presto/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/facebook/presto/downloads","issues_url":"https://api.github.com/repos/facebook/presto/issues{/number}","pulls_url":"https://api.github.com/repos/facebook/presto/pulls{/number}","milestones_url":"https://api.github.com/repos/facebook/presto/milestones{/number}","notifications_url":"https://api.github.com/repos/facebook/presto/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/facebook/presto/labels{/name}","releases_url":"https://api.github.com/repos/facebook/presto/releases{/id}","created_at":"2012-08-09T01:03:37Z","updated_at":"2015-12-22T05:38:10Z","pushed_at":"2015-12-22T01:07:57Z","git_url":"git://github.com/facebook/presto.git","ssh_url":"git@github.com:facebook/presto.git","clone_url":"https://github.com/facebook/presto.git","svn_url":"https://github.com/facebook/presto","homepage":"https://prestodb.io","size":105949,"stargazers_count":4244,"watchers_count":4244,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1153,"mirror_url":null,"open_issues_count":429,"forks":1153,"open_issues":429,"watchers":4244,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/facebook/presto/pulls/4217"},"html":{"href":"https://github.com/facebook/presto/pull/4217"},"issue":{"href":"https://api.github.com/repos/facebook/presto/issues/4217"},"comments":{"href":"https://api.github.com/repos/facebook/presto/issues/4217/comments"},"review_comments":{"href":"https://api.github.com/repos/facebook/presto/pulls/4217/comments"},"review_comment":{"href":"https://api.github.com/repos/facebook/presto/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/facebook/presto/pulls/4217/commits"},"statuses":{"href":"https://api.github.com/repos/facebook/presto/statuses/40ea56edc35e3128203784624223d35c2219f92c"}}}}