I tried to import all tables using the sqoop into one of the directories.But one of the tables has no primary key.This is the code I executed.
sqoop import-all-tables --connect "jdbc:mysql://quickstart.cloudera/retail_db"
--username=retail_dba
--password=cloudera
--warehouse-dir /user/cloudera/sqoop_import/
I am getting the following error:
Error during import: No primary key could be found for table departments_export. Please specify one with --split-by or perform a sequential import with '-m 1'.
By seeing sqoop import without primary key in RDBMS
I understood that we can just use --split-by
for a single table import.Is there a way i can specify --splity-by
for Import-all-tables
command. Is there a way I can use more than one mapper for the multi-table import with no primary-key.