- Sqoop Tutorial
- Sqoop - Home
- Sqoop - Introduction
- Sqoop - Installation
- Sqoop - Import
- Sqoop - Import-All-Tables
- Sqoop - Export
- Sqoop - Sqoop Job
- Sqoop - Codegen
- Sqoop - Eval
- Sqoop - List Databases
- Sqoop - List Tables
- Sqoop Useful Resources
- Sqoop - Questions and Answers
- Sqoop - Quick Guide
- Sqoop - Useful Resources
- Sqoop - Discussion
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.
Q 1 - To prevent the password from being mentioned in the sqoop import clause we can use the additional parameters
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.
Q 2 - What does the --last-value parameter in sqoop incremental import signify?
A - What is the number of rows sucessfully imported in append type import
D - The count of the number of rows that were succesful in the current import.
Answer : C
Explanation
Sqoop uses the --last-value parameter in both the append mode and the last_update_date mode to import the incremental data form source.
Q 3 - The argument in a saved sqoop job can be altered at run time by using the option
Answer : C
Explanation
For a saved job named 'job1' the --table parameter can be altered at run time by using the command below.
sqoop job --exec job1 -- --table-newtable.
Q 4 - In a table import the name of the mapreduce job
A - Is named after the table name
Answer : A
Explanation
The name of the job is based on the name of the table which is being imported.
Q 5 - Which of the following is a disadvantage of using the –staging-table parameter?
A - Data is stored twice and consumes more memory
B - The overall export time is more than direct export to final table
C - User should ensure the structure of staging table and final tables are in Sync.
Answer : D
Explanation
All the listed options are disadvantages while using the –staging-table option.
Q 6 - Sqoop can insert new rows and update existing changed rows into an already exported table by using the parameter
Answer : D
Explanation
the –update-mode allwoinsert can be used to update as well as insert existing rows into the exported table.
Q 7 - What is the disadvantage of using the –columns parameter to insert a subset of columns to the relational table?
A - The relational table may have not null columns not covered in the –columns parameter.
B - The relational table may store the data from HDFS in wrong columns.
Answer : A
Explanation
If there are columns whose value is mandatory and the HDFS file does not have it in the subset the load will fail.
Q 8 - To overwrite data present in hive table while importing data using sqoop, the sqoop parameter is
Answer : B
Explanation
The --hive-overwrite parameter truncates the hive table before loading the data.
Q 9 - The parameter(s) used to laod data using sqoop into the hive partitions is/are
A - --hive-partition-key and -hive-partition-value
Answer : A
Explanation
both partition-key and partition value are passed in to load data into hive partitioned table.
Q 10 - The property in sqoop that allows rows with all NULL values to be inserted into HBAse tables is −
B - sqoop.hbase.allow.row.nulls,
D - It is not possible as HBAse will never allow rows with all null Columns to be inserted
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.
To Continue Learning Please Login
Login with Google