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 - While SequenceFile stores each record as key-value pair, the avro system stored records as
Answer : D
Explanation
Sqoop generates the schema automatically when reading the data and stores the schema details along with the data in each Avro file generated.
Answer : C
Explanation
You can do both full and partial data import from tables but not a subset of columns from a table.
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 - Data Transfer using sqoop can be
A - only imported into the Hadoop system
Answer : B
Explanation
The data can be both imported and exported form Hadoop system using sqoop.
Q 5 - Using the staging-table parameter while loading data to relational tables the creation of staging table is done
Answer : C
Explanation
The user has to ensure that the staging tab e is created and accessible by sqoop.
Q 6 - With MySQL, the feature used by sqoop for update or insert data into an exported table is
Answer : A
Explanation
The ON DUPLICATE KEY UPDATE feature of mySql is used for update else insert with sqoop.
Q 7 - For Text based columns the parameter used for substituting null values is
Answer : A
Explanation
The input- null-string is used to substitute null values for text based columns.
Q 8 - While importing directly to hive using sqoop, if the table meta data does not exist in hive then
B - sqoop creates the meta data in hive
C - sqoop waits for user to input the meta data
D - sqoop imports the data as a file without creating any meta data
Answer : B
Explanation
as both sqoop and hive are part of hadoop ecosystem, sqoop is able to create the meta data in hive.
Q 9 - The parameter --hive-drop-import-delims does which of the following?
A - replaces the hive delimiters with sqoop delimiters
B - drops the rows which do not have the \n,\t,\01 delimiters
C - removes all the \n,\t and \01 characters
D - drops the columns which do not have the \n,\t,\01 delimiters
Answer : C
Explanation
the parameter --hive-drop-import-delims removes the mentioned characters.
Q 10 - The parameters in sqoop command can be passed in to Oozie by using which tags?
Answer : B
Explanation
The <args> tag can contain the parameters of a sqoop command when scheduling with Oozie.