4

I have a Hive table partitioned on an 'int' column.

I want to export the Hive table to MySql using Sqoop export tool.

sqoop export --connect jdbc:mysql://XXXX:3306/temp --username root --password root --table emp --hcatalog-database temp --hcatalog-table emp

I tried the above sqoop command but it failed with below exception.

ERROR tool.ExportTool: Encountered IOException running export job: java.io.IOException: 
The table provided temp.emp uses unsupported  partitioning key type  for column mth_id : int.  
Only string fields are allowed in partition columns in HCatalog

I understand that the partition on int column is not supported.
But would like to check whether this issue is fixed in any of the latest releases with an extra config/option.

As a workaround, I can create another table without a partition before exporting.
But I would like to check whether there is a better way to achieve this?

Thanks in advance.

Munesh
  • 1,509
  • 3
  • 20
  • 46

0 Answers0