Challenge - 5 Problems
HBase CRUD Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
❓ Predict Output
intermediate2:00remaining
What is the output of this HBase shell command?
Consider the following HBase shell commands executed sequentially:
What will be the output of the
create 'students', 'info' put 'students', 'row1', 'info:name', 'Alice' put 'students', 'row1', 'info:age', '21' get 'students', 'row1', 'info:name'
What will be the output of the
get command?Hadoop
create 'students', 'info' put 'students', 'row1', 'info:name', 'Alice' put 'students', 'row1', 'info:age', '21' get 'students', 'row1', 'info:name'
Attempts:
2 left
💡 Hint
The
get command retrieves the value of the specified column for the given row.✗ Incorrect
The
get command fetches the value stored in the 'info:name' column for 'row1', which is 'Alice'.❓ data_output
intermediate1:30remaining
How many rows remain after this delete operation?
Given a table 'employees' with rows 'emp1', 'emp2', and 'emp3', after running:
How many rows will remain in the table?
deleteall 'employees', 'emp2'
How many rows will remain in the table?
Hadoop
deleteall 'employees', 'emp2'
Attempts:
2 left
💡 Hint
The
deleteall command removes all columns for the specified row.✗ Incorrect
Deleting all columns of 'emp2' removes that row, so only 'emp1' and 'emp3' remain.
🔧 Debug
advanced2:00remaining
Identify the error in this HBase shell command sequence
What error will occur when running this sequence?
create 'products', 'details' put 'products', 'p1', 'details:name', 'Laptop' put 'products', 'p1', 'details:price', 1200 get 'products', 'p1', 'details:price'
Hadoop
create 'products', 'details' put 'products', 'p1', 'details:name', 'Laptop' put 'products', 'p1', 'details:price', 1200 get 'products', 'p1', 'details:price'
Attempts:
2 left
💡 Hint
HBase shell converts numbers to strings automatically in
put.✗ Incorrect
HBase shell treats all values as strings, so 1200 is stored as '1200' without error.
🚀 Application
advanced1:30remaining
Which command updates a cell value in HBase?
You want to change the value of the cell in row 'r1', column 'info:status' to 'active' in the 'users' table. Which command will do this?
Attempts:
2 left
💡 Hint
HBase uses
put to insert or update data.✗ Incorrect
The
put command inserts or updates the value of a cell in HBase.🧠 Conceptual
expert1:30remaining
What happens if you try to get a non-existent row in HBase?
If you run
get 'orders', 'order999' but 'order999' does not exist in the 'orders' table, what will be the result?Hadoop
get 'orders', 'order999'
Attempts:
2 left
💡 Hint
HBase returns empty results for missing rows instead of errors.
✗ Incorrect
If the row does not exist, HBase returns an empty result without error.