Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-26227

Add support of catalog related statements for Hive ql

Log workAgile BoardRank to TopRank to BottomBulk Copy AttachmentsBulk Move AttachmentsAdd voteVotersWatch issueWatchersCreate sub-taskConvert to sub-taskMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Task
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • Hive

    Description

      Catalog concept is proposed to Hive 3.0 to allow different systems to connect to different catalogs in the metastore. But so far we can not query catalog through Hive ql, this task aims to implement the ddl statements related to catalog.

      Create Catalog

      CREATE CATALOG [IF NOT EXISTS] catalog_name
      LOCATION hdfs_path
      [COMMENT catalog_comment];
      

      LOCATION is required for creating a new catalog now.

      Alter Catalog

      ALTER CATALOG catalog_name SET LOCATION hdfs_path;
      

      Only location metadata can be altered for catalog.

      Drop Catalog

      DROP CATALOG [IF EXISTS] catalog_name;
      

      DROP CATALOG is always RESTRICT, which means DROP CATALOG will fail if there are non-default databases in the catalog.
      Show Catalogs

      SHOW CATALOGS [LIKE 'identifier_with_wildcards'];
      

      SHOW CATALOGS lists all of the catalogs defined in the metastore.
      The optional LIKE clause allows the list of catalogs to be filtered using a regular expression.
      Describe Catalog

      DESC[RIBE] CATALOG [EXTENDED] cat_name;
      

      DESCRIBE CATALOG shows the name of the catalog, its comment (if one has been set), and its root location on the filesystem.
      EXTENDED also shows the create time.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            wechar Wechar Assign to me
            wechar Wechar

            Dates

              Created:
              Updated:

              Time Tracking

              Estimated:
              Original Estimate - Not Specified
              Not Specified
              Remaining:
              Remaining Estimate - 0h
              0h
              Logged:
              Time Spent - 1h 10m
              1h 10m

              Slack

                Issue deployment