Input command hbase Shell enters
To view all tables that exist:
List
To view the table structure:
Describe ' table name '
Query the contents of the table:
Scan ' TABLENAME '-----For example have a student table to view it scan ' student '
Add, update data : Put
Put ' table name ', ' Row ', ' column ', ' value '-----For example add row to Wangsong, Column=info:name value is Dabaicai row of records
Put ' student ', ' wangsong ', ' info:name ', ' dabaicai '-----then scan ' student ' to see if adding Li is equivalent to modifying the update operation if the data is in some cases
Delete data: Delete and DeleteAll
Delete a column value in a row: Delete ' table name ', ' Row ', ' column '-----such as delete ' student ', ' wangsong ', ' info:name '
Delete Row: DeleteAll ' table name ', ' row '-----such as deleteall ' student ', ' Wangsong '
Delete all data in table: Truncate ' table name '-----For example truncate ' student '
Get data: Get
Get a row of data in the table: Get ' table name ', ' ROW '-----For example I want to get Wangsong's data put ' student ', ' Wangsong ' will find Wangsong under all column
Get the data for a column: Get ' table name ', ' ROW ', ' column ' to get '-----get ' student ', ' wangsong ', ' info:name ' to get Info:name value Dabaicai
Learn Hbase Shell basic additions and deletions to change statements