accumulo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From z11373 <z11...@outlook.com>
Subject using Range.prefix
Date Tue, 03 May 2016 13:55:43 GMT
Hi,
I have a table that contains following rows:

20160421_a484869 cf: [public]
20160421_f109973 cf: [public]

And I have following code:

    		Authorizations publicAuthz = new Authorizations("public");
    		Scanner scanner = connector.createScanner(TABLE, publicAuthz);
    		Text rowPrefix = new Text("20160421");
    		Range range = Range.prefix(rowPrefix, new Text("cf"));
    		scanner.setRange(range);
    		for (Entry<Key, Value> entry : scanner) {
    			String key = entry.getKey().toString();
    			System.out.println(key);
    		}


The loop is not entered, which is unexpected to me. If I comment the
setRange code, then it'll print out both row ids. Can you tell me what I
missed here?

Thanks,
Z



--
View this message in context: http://apache-accumulo.1065345.n5.nabble.com/using-Range-prefix-tp16835.html
Sent from the Developers mailing list archive at Nabble.com.

Mime
View raw message