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 - The parameter in sqoop which specifies the output directories when importing data is

A - --output-path

B - --target-path

C - --output-dir

D - --target-dir

Answer : D

Explanation

The --target-dir and --warehouse-dir are the two parameters used for specifying the path where import will be done.

Q 2 - For some databases sqoop can to faster data transefr by using the parameter

A - --bulkload

B - --fastload

C - --dump

D - --direct

Answer : D

Explanation

The direct mode delegates the data transferring capabilities to the native untilities provided by the database.

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.

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 : C

Explanation

In the scenario when the database requires table_level write lock, higher value of sqoop.export.statements.per.transaction will lock the table for a longer time and will decrease the performance.

Answer : A

Explanation

only the columns other than in the –update-key parameter will be appear in the SET clause.

Answer : B

Explanation

The load can still be done by specifying the –column parameter to populate a subset of columns in the relational table.

Q 8 - To overwrite data present in hive table while importing data using sqoop, the sqoop parameter is

A - --sqoop-overwrite

B - --hive-overwrite

C - --hive-delete-all

D - --sqoop-delete-all

Answer : B

Explanation

The --hive-overwrite parameter truncates the hive table before loading the data.

Answer : C

Explanation

the parameter --hive-drop-import-delims removes the mentioned characters.

Answer : A

Explanation

The property sqoop.hbase.add.row.key instructs Sqoop to insert the row key column twice, once as a row identifier and then again in the data itself. Even if all other columns contain NULL, at least the column used for the row key won’t be null, which will allow the insertion of the row into HBase.

sqoop_questions_answers.htm
Advertisements