Following quiz provides Multiple Choice Questions (MCQs) related to Hive. 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 - Each database created in hive is stored as
Each database becomes a directory and each table becomes a file in that directory
Q 2 - The drawback of managed tables in hive is
As they are managed by Hive metadata, other applications cannot access it.
Q 3 - The "strict" mode when querying a partitioned table is used to
The strict mode is designed to avoid long running jobs.
Q 4 - While querying a hive table for a column with MAP data type, the elements in the column are referenced by
The MAP data type is a key-value pair and not index based.
Q 5 - Consider the query SELECT explode(city_locality) from ALL_LOCALITIES , where city_locality is a ARRAY dat atype. This will return
The explode() function expands each element of ARRAY into a row.
Q 6 - The DISTRIBUTED by clause is used to ensure that
The DISTRIBUTED BY clause send a range of values to the same reducer.
Q 7 - Consider the below two sets of queries.
Query A: hive> INSERT OVERWRITE TABLE sales SELECT * FROM history WHERE action = 'purchased'; hive> INSERT OVERWRITE TABLE credits SELECT * FROM history WHERE action = 'returned'; and Query B: hive> FROM history INSERT OVERWRITE sales SELECT * WHERE action = 'purchased' INSERT OVERWRITE credits SELECT * WHERE action = 'returned'
Which of them will make a single pass through?
in Query B, the query is executed only once.
Q 8 - The disadvantage of compressing files in HDFS is
When files are not splitable , querying them becomes inefficient.
Q 9 - Which of the below is not a type compression option for Sequence file
There is no COLUMN compression type for a sequence file
Q 10 - The Hive metadata can be easily created and edited using
Hcatalog stores metadata information for many Hadoop tools like Hive and Mapreduce. It can be accessed through a web interface.