Explanation: HTable API one of the put method is as below public void put(Put put) throws InterruptedIOException, RetriesExhaustedWithDetailsException Puts some data in the table. If isAutoFlush is false, the update is buffered until the internal buffer is full.
Specified by: put in interface Table Parameters: put - The data to put.
Question : Given the following HBase code: byte [] rowKey = Bytes.toBytes(65); Get get = new Get(rowKey); Result result = customers.get(get);
Which one of the following statements is true?
1. The result variable will contain all values from all column families for the row whose key is 65 2. The result variable in this example will always be null 3. Access Mostly Uused Products by 50000+ Subscribers 4. The result variable will not contain any values and can be used for retrieving the column values
Explanation: public Get(byte[] row) Create a Get operation for the specified row. If no further operations are done, this will get the latest version of all columns in all families of the specified row.
Parameters: row - row key
Question : Given the following HBase code:
byte [] rowKey = Bytes.toBytes(65); Get get = new Get(rowKey); get.addFamily("info".getBytes()); Result result = customers.get(get);
Which one of the following statements is true?
1. The method call to addFamily does not compile 2. The result will contain all values from all column families for the row whose key is 65 3. Access Mostly Uused Products by 50000+ Subscribers 4. The result will contain all values from the "info" column qualifier for the row whose key is 65
1. The result variable will contain all values from all column families for the row whose key is 65 2. The result variable in this example will always be null 3. Access Mostly Uused Products by 50000+ Subscribers 4. The result variable will not contain any values and can be used for retrieving the column values
1. The method call to addFamily does not compile 2. The result will contain all values from all column families for the row whose key is 65 3. Access Mostly Uused Products by 50000+ Subscribers 4. The result will contain all values from the "info" column qualifier for the row whose key is 65