{"action":"created","issue":{"url":"https://api.github.com/repos/apache/spark/issues/9337","labels_url":"https://api.github.com/repos/apache/spark/issues/9337/labels{/name}","comments_url":"https://api.github.com/repos/apache/spark/issues/9337/comments","events_url":"https://api.github.com/repos/apache/spark/issues/9337/events","html_url":"https://github.com/apache/spark/pull/9337","id":113851800,"number":9337,"title":"[SPARK-11379][SQL] ExpressionEncoder can't handle top level primitive type correctly","user":{"login":"cloud-fan","id":3182036,"avatar_url":"https://avatars.githubusercontent.com/u/3182036?v=3","gravatar_id":"","url":"https://api.github.com/users/cloud-fan","html_url":"https://github.com/cloud-fan","followers_url":"https://api.github.com/users/cloud-fan/followers","following_url":"https://api.github.com/users/cloud-fan/following{/other_user}","gists_url":"https://api.github.com/users/cloud-fan/gists{/gist_id}","starred_url":"https://api.github.com/users/cloud-fan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cloud-fan/subscriptions","organizations_url":"https://api.github.com/users/cloud-fan/orgs","repos_url":"https://api.github.com/users/cloud-fan/repos","events_url":"https://api.github.com/users/cloud-fan/events{/privacy}","received_events_url":"https://api.github.com/users/cloud-fan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-10-28T15:44:33Z","updated_at":"2015-10-29T02:16:16Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/apache/spark/pulls/9337","html_url":"https://github.com/apache/spark/pull/9337","diff_url":"https://github.com/apache/spark/pull/9337.diff","patch_url":"https://github.com/apache/spark/pull/9337.patch"},"body":"For inner primitive type(e.g. inside `Product`), we use `schemaFor` to get the catalyst type for it, https://github.com/apache/spark/blob/master/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/ScalaReflection.scala#L403.\r\n\r\nHowever, for top level primitive type, we use `dataTypeFor`, which is wrong."},"comment":{"url":"https://api.github.com/repos/apache/spark/issues/comments/152053300","html_url":"https://github.com/apache/spark/pull/9337#issuecomment-152053300","issue_url":"https://api.github.com/repos/apache/spark/issues/9337","id":152053300,"user":{"login":"SparkQA","id":8108735,"avatar_url":"https://avatars.githubusercontent.com/u/8108735?v=3","gravatar_id":"","url":"https://api.github.com/users/SparkQA","html_url":"https://github.com/SparkQA","followers_url":"https://api.github.com/users/SparkQA/followers","following_url":"https://api.github.com/users/SparkQA/following{/other_user}","gists_url":"https://api.github.com/users/SparkQA/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkQA/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkQA/subscriptions","organizations_url":"https://api.github.com/users/SparkQA/orgs","repos_url":"https://api.github.com/users/SparkQA/repos","events_url":"https://api.github.com/users/SparkQA/events{/privacy}","received_events_url":"https://api.github.com/users/SparkQA/received_events","type":"User","site_admin":false},"created_at":"2015-10-29T02:16:16Z","updated_at":"2015-10-29T02:16:16Z","body":"**[Test build #44553 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/44553/consoleFull)** for PR 9337 at commit [`8b98d03`](https://github.com/apache/spark/commit/8b98d038ac2723deb4a261203bed01a614863d39).\n * This patch passes all tests.\n * This patch merges cleanly.\n * This patch adds no public classes."}}