Sqoop Online Quiz



Following quiz provides Multiple Choice Questions (MCQs) related to Sqoop. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Q 1 - What are the two binary file formats supported by sqoop?

A - Avro & SequenceFile

B - Rcfile and SequenceFile

C - ORC file and RC file

D - Avro and RC file

Answer : A

Explanation

These are the two binary file formats supported by Sqoop.

Answer : B

Explanation

Sqoop does not have any inbuilt code to carry out file compression. It relies on Hadoop's compression settings.

Answer : A

Explanation

The WHERE $CONDITION is used to split the result of the SQL query into multiple chunks.

Q 4 - While inserting data into Relational system from Hadoop using sqoop, the various table constraints present in the relational table must be

A - Disabled temporarily

B - Dropped and re created

C - Renamed

D - Not violated

Answer : D

Explanation

We must verify that the data being exported does not violate the constraints error.

Answer : D

Explanation

The parameter

Dsqoop.export.statements.per.transaction decides how many rows will be inserted for transaction.

Q 6 - Sqoop can insert new rows and update existing changed rows into an already exported table by using the parameter

A - update-insert

B - -update-else-insert

C - update-mode insert

D - update-mode allowinsert

Answer : D

Explanation

the update-mode allwoinsert can be used to update as well as insert existing rows into the exported table.

Q 7 - The parameter to specify only a selected number of columns to be exported to a table is

A - -columns

B - column-subset

C - ----columns-not-all

D - -columns-part

Answer : A

Explanation

The columns clause will take a comma separated values of column names which will be part of the export.

Q 8 - To ensure that the columns created in hive by sqoop have the correct data types the parameter used by sqoop is

A - --map-column-hive

B - --map-column

C - --column-hive

D - --map-table-hive

Answer : A

Explanation

The correct column mapping is handled by the parameter --map-column-hive.

Answer : C

Explanation

As the characters \n, \t, and \01 may interfere with the data giving incorrect result, these can be replaced with a suitable string using this parameter.

Q 10 - The sqoop export/import jobs canbe stored and used again and again by using

A - sqoop- jobname

B - sqoop-save-job

C - sqoop-all-jobs

D - sqoop-job

Answer : D

Explanation

Running a sqoop job by using sqoop-job statement saves the job into metastore which can be retrived later and used again and again

Example −

$ sqoop-job --create jobname -- import --connect jdbc:mysql://example.com/db \
   --table mytable
sqoop_questions_answers.htm
Advertisements