- Hive - Home
- Hive - Introduction
- Hive - Installation
- Hive - Data Types
- Hive - Create Database
- Hive - Drop Database
- Hive - Create Table
- Hive - Alter Table
- Hive - Drop Table
- Hive - Partitioning
- Hive - Built-In Operators
- Hive - Built-In Functions
- Hive - Views And Indexes
- Hive Useful Resources
- Hive - Questions and Answers
- Hive - Quick Guide
- Hive - Useful Resources
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.
Q 1 - The query "SHOW DATABASE LIKE 'h.*' ; gives the output with database name
Answer : B
Explanation
Hive support regular expressions which are derived from regex capabilities of Java language.
Q 2 - By default when a database is dropped in Hive
A - the tables are also deleted
B - the directory is deleted if there are no tables
Answer : B
Explanation
Hive does not recursively delete the directory. So tables must be dropped first.
Q 3 - The main advantage of creating table partition is
A - Effective storage memory utilization
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
Answer : A
Explanation
Only a internal table can be created and loaded with data using one query.
Q 5 - The CONCAT string function in Hive can concatenate
Answer : C
Explanation
CONCAT function accepts any number of arguments
Q 6 - A view in Hive can be seen by using
Answer : A
Explanation
There is no separate clause for viewing views. It is shown using show tables.
Q 7 - If the data on the table on which an index is defined changes then,
B - The index rebuilds automatically
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
Answer : A
Explanation
This parameter is configured to change the default value of the number of rows returned
Q 9 - A Table Generating Function is a Function that
A - Takes one or more columns form a row and returns a single value
B - Takes one or more columns form many rows and returns a single value
C - Take zero or more inputs and produce multiple columns or rows of output
D - Detects the type of input programmatically and provides appropriate response
Answer : C
Explanation
Examples functions is Explode()
Q 10 - The Hive metadata can be easily created and edited using
Answer : A
Explanation
Hcatalog stores metadata information for many Hadoop tools like Hive and Mapreduce. It can be accessed through a web interface.