Hive Online Quiz



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.

Questions and Answers

Q 1 - The query "SHOW DATABASE LIKE 'h.*' ; gives the output with database name

A - containing h in their name

B - starting with h

C - ending with h

D - containing 'h.'

Answer : B

Explanation

Hive support regular expressions which are derived from regex capabilities of Java language.

Answer : B

Explanation

Hive does not recursively delete the directory. So tables must be dropped first.

Answer : B

Explanation

Partitioning creates subdirectories and only those subdirectories are read to fetch the query result, improving the performance.

Q 4 - Creating a table an loading it with a select clause in one query applies to

A - only managed tables

B - only external tables

C - Both types of tables

D - Only tables without partitions

Answer : A

Explanation

Only a internal table can be created and loaded with data using one query.

Answer : C

Explanation

CONCAT function accepts any number of arguments

Q 6 - A view in Hive can be seen by using

A - SHOW TABLES

B - SHOW VIEWS

C - DESCRIBE VIEWS

D - VIEW VIEWS

Answer : A

Explanation

There is no separate clause for viewing views. It is shown using show tables.

Answer : C

Explanation

Hive does not manage the Index like RDBMS. SO it has to be built manually.

Q 8 - The default limit to the number of rows returned by a query can be done using which of the following parameter?

A - hive.limit.optimize.enable

B - hive.limit.enable.optimize

C - hive.optimize.enable.limit

D - hive.enable.limit.optimize

Answer : A

Explanation

This parameter is configured to change the default value of the number of rows returned

Q 10 - The Hive metadata can be easily created and edited using

A - HCatalog

B - HMetamanager

C - Hweblog

D - Hue

Answer : A

Explanation

Hcatalog stores metadata information for many Hadoop tools like Hive and Mapreduce. It can be accessed through a web interface.

hive_questions_answers.htm
Advertisements