.../java/org/apache/hadoop/hbase/io/hfile/HFilePrettyPrinter.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/HFilePrettyPrinter.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/HFilePrettyPrinter.java index 98154f92d8..cb68cdcafc 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/HFilePrettyPrinter.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/HFilePrettyPrinter.java @@ -326,8 +326,11 @@ public class HFilePrettyPrinter extends Configured implements Tool { boolean shouldScanKeysValues = false; if (this.isSeekToRow) { // seek to the first kv on this row - shouldScanKeysValues = - (scanner.seekTo(PrivateCellUtil.createFirstOnRow(this.row)) != -1); + if (Bytes.equals(row, reader.getFirstRowKey().get())) { + shouldScanKeysValues = scanner.seekTo(); + } else { + shouldScanKeysValues = (scanner.seekTo(PrivateCellUtil.createFirstOnRow(this.row)) != -1); + } } else { shouldScanKeysValues = scanner.seekTo(); }