Dear Wiki user, You have subscribed to a wiki page or wiki category on "Hadoop Wiki" for change notification.
The following page has been changed by udanax: http://wiki.apache.org/hadoop/Hbase/HbaseShell ------------------------------------------------------------------------------ '''Note''' that attribute values are quoted with either single or double quotes. === Database administration language === ||<bgcolor="#ececec">'''Syntax''' ||<bgcolor="#ececec">'''Explanation''' || - ||Help ||<99%>'''Help''' syntax provides information about the use of shell script.[[BR]][[BR]]~-''HELP [function_name];''-~ || + ||Help ||<99%>'''Help''' provides information about the use of shell script.[[BR]][[BR]]~-''HELP [function_name];''-~ || - ||Show ||<99%>'''Show''' syntax lists tables.[[BR]][[BR]]~-''SHOW tables;''-~ || + ||Show ||<99%>'''Show''' lists tables.[[BR]][[BR]]~-''SHOW tables;''-~ || - ||Describe ||'''Describe''' syntax provides information about the columnfamilies in a table.[[BR]][[BR]]~-''DESC table_name;''-~ || + ||Describe ||'''Describe''' provides information about the columnfamilies in a table.[[BR]][[BR]]~-''DESC table_name;''-~ || + ||Load ||<99%>'''Load''' query file and execute the queries.[[BR]][[BR]]~-'''load hdfs://hbase/query_file.hql';''-~ || ||FS ||<99%>'''Filesystem''' commands.[[BR]][[BR]]~-''FS [-option] arguments...;''-~ || ||JAR ||<99%>'''JAR''' syntax to run hadoop jar commands.[[BR]][[BR]]~-''JAR jarFile [mainClass] args...;''-~|| ||Clear ||<99%>'''Clear''' the screen.[[BR]][[BR]]~-''CLEAR;''-~ || @@ -52, +53 @@ Data definition langague to define data tables ||<bgcolor="#ececec">'''Syntax''' ||<bgcolor="#ececec">'''Explanation''' || - ||Create ||<99%>'''Create''' syntax creates a new table.[[BR]][[BR]]~-''CREATE TABLE table_name ([[BR]]{{{ }}}column_family_definition[[BR]]{{{ }}}[, column_family_spec][[BR]]{{{ }}}...[[BR]])[[BR]][[BR]]''-~'''colum_family_definition:'''~-''[[BR]]column_family_name[[BR]]{{{ }}}[MAX_VERSIONS=n][[BR]]{{{ }}}[MAX_LENGTH=n][[BR]]{{{ }}}[COMPRESSION=NONE|BLOCK|RECORD][[BR]]{{{ }}}[IN_MEMORY][[BR]]{{{ }}}[BLOOMFILTER=NONE|BLOOMFILTER|COUNTING_BLOOMFILTER|RETOUCHED_BLOOMFILTER VECTOR_SIZE=n NUM_HASH=n]''-~ || + ||Create ||<99%>'''Create''' a new table.[[BR]][[BR]]~-''CREATE TABLE table_name ([[BR]]{{{ }}}column_family_definition[[BR]]{{{ }}}[, column_family_spec][[BR]]{{{ }}}...[[BR]])[[BR]][[BR]]''-~'''colum_family_definition:'''~-''[[BR]]column_family_name[[BR]]{{{ }}}[MAX_VERSIONS=n][[BR]]{{{ }}}[MAX_LENGTH=n][[BR]]{{{ }}}[COMPRESSION=NONE|BLOCK|RECORD][[BR]]{{{ }}}[IN_MEMORY][[BR]]{{{ }}}[BLOOMFILTER=NONE|BLOOMFILTER|COUNTING_BLOOMFILTER|RETOUCHED_BLOOMFILTER VECTOR_SIZE=n NUM_HASH=n]''-~ || ||Alter ||<99%>'''Alter''' syntax changes the structure of the specified table.[[BR]][[BR]]~-''ALTER TABLE table_name[[BR]]{{{ }}}alter_definition [, alter_definition] ...[[BR]][[BR]]''-~'''alter_definition:'''~-''[[BR]]{{{ }}}ADD column_family_definition[[BR]]{{{ }}}| ADD (column_family_definition, ...)[[BR]]{{{ }}}| DROP column_family_name[[BR]]{{{ }}}| CHANGE column_family_name column_family_definition''-~|| - ||Drop ||'''Drop''' syntax drops columnfamilies in a table or tables.[[BR]][[BR]]~-''DROP TABLE table_name1[, table_name2, ...];''-~ || + ||Drop ||'''Drop''' columnfamilies in a table or tables.[[BR]][[BR]]~-''DROP TABLE table_name1[, table_name2, ...];''-~ || - ||Truncate ||'''Truncate''' Syntax cleans all data from a table. [[BR]][[BR]]~-''TRUNCATE TABLE table_name;''-~ || + ||Truncate ||'''Truncate''' cleans all data from a table. [[BR]][[BR]]~-''TRUNCATE TABLE table_name;''-~ || === Data manipulation language === Data manipulation language to manually manipulate data on more detailed parts ||<bgcolor="#ececec">'''Syntax''' ||<bgcolor="#ececec">'''Explanation''' || - ||Insert ||<99%>'''Insert''' syntax inserts one row into the table with a value for specified column in the table.[[BR]][[BR]]~-''INSERT INTO table_name (colmn_name, ...)[[BR]]{{{ }}}VALUES ('value', ...)[[BR]]{{{ }}}WHERE row = 'row-key'[[BR]]{{{ }}}[TIMESTAMP 'timestamp'];''-~ || + ||Insert ||<99%>'''Insert''' one row into the table with a value for specified column in the table.[[BR]][[BR]]~-''INSERT INTO table_name (colmn_name, ...)[[BR]]{{{ }}}VALUES ('value', ...)[[BR]]{{{ }}}WHERE row = 'row-key'[[BR]]{{{ }}}[TIMESTAMP 'timestamp'];''-~ || - ||Delete ||'''Delete''' syntax deletes specified rows in table. [[BR]][[BR]]~-''DELETE { column_name, [, column_name] ... | COLUMNFAMILIES(column_family[, column_family] ... | *} [[BR]]{{{ }}}FROM table_name[[BR]]{{{ }}}[WHERE row = 'row-key'];''-~ || + ||Delete ||'''Delete''' specified rows in table. [[BR]][[BR]]~-''DELETE { column_name, [, column_name] ... | COLUMNFAMILIES(column_family[, column_family] ... | *} [[BR]]{{{ }}}FROM table_name[[BR]]{{{ }}}[WHERE row = 'row-key'];''-~ || ||Select ||<99%>'''Select''' syntax retrieves rows from a table.[[BR]]Several aggregate operators: COUNT()[[BR]][[BR]]~-''SELECT { column_name [, column_name] ... | expr[alias] | * }[[BR]]{{{ }}}FROM table_name[[BR]]{{{ }}}[WHERE row = 'row-key' | STARTING FROM 'row-key' [UNTIL 'stop-key']][[BR]]{{{ }}}[NUM_VERSIONS = version_count][[BR]]{{{ }}}[TIMESTAMP 'timestamp'][[BR]]{{{ }}}[LIMIT = row_count][[BR]]{{{ }}}[INTO FILE 'file_name'][[BR]][[BR]]''-~'''column_name:'''~-''[[BR]]{{{ }}}column_family_name[[BR]]{{{ }}}| column_family_name:column_label_name''-~ || == Comparison table between SQL and HQL ==
