How to do Hive to Hive data Export?

Viewing 1 reply thread
  • Author
    Posts
    • #5303
      DataFlair TeamDataFlair Team
      Spectator

      How to do Hive to Hive data Export?
      give the query as well.

    • #5304
      DataFlair TeamDataFlair Team
      Spectator

      The EXPORT command exports the data of a table or partition, along with the metadata, into a specified output location. Exported metadata is stored in the target directory, and data files are stored in subdirectories. The query is:

      EXPORT TABLE tablename [PARTITION (part_column=”value”)]
      TO ‘targeted export location’

      Under the directory identified as the targeted export location, the export command will create a _metadata file containing table definition information. If the table is not partitioned, a subdirectory named data will be created under the target export location and within it will be copied the data for the table. If the table is partitioned, then a subdirectory for each partition is created under the targeted export location to hold that partition’s data.

Viewing 1 reply thread
  • You must be logged in to reply to this topic.