Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-11778

HiveContext.read.table does not support user-specified database names

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • 1.5.1
    • 1.6.0
    • SQL

    Description

      If we have defined a HiveContext instance

      val hiveContext = new org.apache.spark.sql.hive.HiveContext(sparkContext)

      then

      hiveContext.table("db_name.table")

      works but

      hiveContext.read.table("db_name.table")

      throws an org.apache.spark.sql.catalyst.analysis.NoSuchTableException
      However,

      hiveContext.sql("use db_name")
      hiveContext.read.table("table")

      works as expected

      Attachments

        Activity

          People

            huaxingao Huaxin Gao
            shadjiiski Stanislav Hadjiiski
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: