{"action":"created","issue":{"url":"https://api.github.com/repos/apache/spark/issues/15054","repository_url":"https://api.github.com/repos/apache/spark","labels_url":"https://api.github.com/repos/apache/spark/issues/15054/labels{/name}","comments_url":"https://api.github.com/repos/apache/spark/issues/15054/comments","events_url":"https://api.github.com/repos/apache/spark/issues/15054/events","html_url":"https://github.com/apache/spark/pull/15054","id":176302464,"number":15054,"title":"[SPARK-17502] [SQL] Fix Multiple Bugs in DDL Statements on Temporary Views","user":{"login":"gatorsmile","id":11567269,"avatar_url":"https://avatars.githubusercontent.com/u/11567269?v=3","gravatar_id":"","url":"https://api.github.com/users/gatorsmile","html_url":"https://github.com/gatorsmile","followers_url":"https://api.github.com/users/gatorsmile/followers","following_url":"https://api.github.com/users/gatorsmile/following{/other_user}","gists_url":"https://api.github.com/users/gatorsmile/gists{/gist_id}","starred_url":"https://api.github.com/users/gatorsmile/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gatorsmile/subscriptions","organizations_url":"https://api.github.com/users/gatorsmile/orgs","repos_url":"https://api.github.com/users/gatorsmile/repos","events_url":"https://api.github.com/users/gatorsmile/events{/privacy}","received_events_url":"https://api.github.com/users/gatorsmile/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":10,"created_at":"2016-09-12T06:24:28Z","updated_at":"2016-09-15T09:02:05Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/apache/spark/pulls/15054","html_url":"https://github.com/apache/spark/pull/15054","diff_url":"https://github.com/apache/spark/pull/15054.diff","patch_url":"https://github.com/apache/spark/pull/15054.patch"},"body":"### What changes were proposed in this pull request?\r\n- When the permanent tables/views do not exist but the temporary view exists, the expected error should be `NoSuchTableException` for partition-related ALTER TABLE commands. However, it always reports a confusing error message. For example, \r\n```\r\nPartition spec is invalid. The spec (a, b) must match the partition spec () defined in table '`testview`';\r\n```\r\n- When the permanent tables/views do not exist but the temporary view exists, the expected error should be `NoSuchTableException` for `ALTER TABLE ... UNSET TBLPROPERTIES`. However, it reports a missing table property. For example, \r\n```\r\nAttempted to unset non-existent property 'p' in table '`testView`';\r\n```\r\n- When `ANALYZE TABLE` is called on a view or a temporary view, we should issue an error message. However, it reports a strange error:\r\n```\r\nANALYZE TABLE is not supported for Project\r\n```\r\n\r\n- When inserting into a temporary view that is generated from `Range`, we will get the following error message:\r\n```\r\nassertion failed: No plan for 'InsertIntoTable Range (0, 10, step=1, splits=Some(1)), false, false\r\n+- Project [1 AS 1#20]\r\n   +- OneRowRelation$\r\n```\r\n\r\nThis PR is to fix the above four issues.\r\n\r\n### How was this patch tested?\r\nAdded multiple test cases"},"comment":{"url":"https://api.github.com/repos/apache/spark/issues/comments/247274931","html_url":"https://github.com/apache/spark/pull/15054#issuecomment-247274931","issue_url":"https://api.github.com/repos/apache/spark/issues/15054","id":247274931,"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":"2016-09-15T09:02:05Z","updated_at":"2016-09-15T09:02:05Z","body":"**[Test build #65428 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/65428/consoleFull)** for PR 15054 at commit [`333497a`](https://github.com/apache/spark/commit/333497a6986902853355e5e322925e3301859882).\n * This patch **fails Spark unit tests**.\n * This patch merges cleanly.\n * This patch adds the following public classes _(experimental)_:\n  * `  public static final class UnsignedPrefixComparatorNullsLast extends RadixSortSupport `\n  * `  public static final class UnsignedPrefixComparatorDescNullsFirst extends RadixSortSupport `\n  * `  public static final class SignedPrefixComparatorNullsLast extends RadixSortSupport `\n  * `  public static final class SignedPrefixComparatorDescNullsFirst extends RadixSortSupport `\n  * `abstract sealed class NullOrdering `\n  * `case class SortOrder(`\n  * `trait Command extends LeafNode `\n  * `trait RunnableCommand extends logical.Command `\n  * `case class CreateTable(`\n  * `case class AnalyzeCreateTable(sparkSession: SparkSession) extends Rule[LogicalPlan] `\n  * `    class SetAccumulator[T] extends AccumulatorV2[T, java.util.Set[T]] `"}}
{"actor":{"display_login":"SparkQA"}}