Details
-
New Feature
-
Status: Resolved
-
Normal
-
Resolution: Fixed
Description
I have been looking for showing rows and paging through rows. Finally I write this extension to cassandra-cli tool.
Let's assume that we have the following data in column family named 'CF1':
=========================
Row 1:
key: fdu1, name: 'Frank Du', city: 'NYC'
Row 2:
key: fdu2, name: 'Jonathan Ellis'
Row 3:
key: fdu3, name: 'Eric Evans'
Syntax:
=========================
LIST keyRangeExpression limitClause?
keyRangeExpression:
columnFamilyName[ startKey : endKey ] ( [ 'superCoumnName' ] )?
limitClause:
LIMIT count (OFFSET offset)?
| LIMIT offset, count
The limit clause is the same with MySql.
Examples:
=========================
// list all the 3 rows in CF1
list CF1[ '' : '' ]
// list all rows, offset from index 1. So it will show 2 rows
list CF1[ '' : '' ] limit 1, 10
// show the rows 'fdu2' and 'fdu3'
list CF1[ 'fdu2' : '' ] limit 10
Attachments
Attachments
Issue Links
- relates to
-
CASSANDRA-1073 EOFException with Cassandra.Client.get_range_slices() API
- Resolved