Github user chenghao-intel commented on a diff in the pull request:

    https://github.com/apache/spark/pull/2570#discussion_r19386385
  
    --- Diff: 
sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveStrategies.scala ---
    @@ -160,17 +162,14 @@ private[hive] trait HiveStrategies {
         def apply(plan: LogicalPlan): Seq[SparkPlan] = plan match {
           case logical.InsertIntoTable(table: MetastoreRelation, partition, 
child, overwrite) =>
             InsertIntoHiveTable(table, partition, planLater(child), 
overwrite)(hiveContext) :: Nil
    -
    -      case logical.CreateTableAsSelect(database, tableName, child) =>
    -        val query = planLater(child)
    +      case logical.CreateTableAsSelect(
    +             Some(database), tableName, child, allowExisting, Some(extra: 
ASTNode)) =>
    --- End diff --
    
    yes, it's always specified here, we just to extract the real value in 
pattern matching, so, we can use the variable `database` directly later on, 
otherwise, we need to call `database.get`


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to