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 - To prevent the password from being mentioned in the sqoop import clause we can use the additional parameters

A - -p

B - --password-file

C - both of these

D - cannot be prevented

Answer : C

Explanation

The -P option asks for password from standard input without echoing and --password-file option reads the password value stored in some other file.

Answer : B

Explanation

The default number of map task ssqoop uses is 4.

This can be altered using num-mappers parameter.

Q 3 - while specifying the connect string in the sqoop import command, for a Hadoop cluster, if we specify localhost in place of a server address(hostname or IP address) in the URI, then

A - The import job will connect to local databases

B - Each node may connect to different databases

C - the import job may succeed

D - All of the above

Answer : D

Explanation

Specifying localhost does not invalidate the command as some local database may be running and the node will be able to connect. So each node will connect to different database if they are available.

Answer : C

Explanation

Every time a sqoop command is submitted, it verifies the metadata of the table before starting the export.

Answer : A

Explanation

sqoop runs another mapreduce job to load the final table after the staging load completes successfully.

Q 6 - Sqoop can automatically clear the staging table before loading by using the parameter

A - clear-table

B - clear-staging-table

C - --truncate-staging-table

D - -delete-from-staging-table

Answer : B

Explanation

the clear-staging-table automatically cleans data form the staging 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 - The parameter used in sqoop to import data directly into hive is

A - -import-direct

B - -import-hive

C - hive-import

D - -hive-sqoop

Answer : C

Explanation

The parameter used is hive-import which will directly place the data in hie without needing any connectors as in case of relational systems.

Answer : A

Explanation

The new line characters present in data will increase the number of rows.

Q 10 - The parameters in sqoop command can be passed in to Oozie by using which tags?

A - <parameters>

B - <args>

C - <sqoop>

D - <command>

Answer : B

Explanation

The <args> tag can contain the parameters of a sqoop command when scheduling with Oozie.

sqoop_questions_answers.htm
Advertisements