How to get total rows from view with key?

40-rc

#1

In View Query, can get total rows of this View by ‘meta’.‘total_rows’.
But in the case i want to get total rows with any key, what is attribute for this value?

Thanks


#2

Every non-reduce view query through the SDK will expose the total rows. Which SDK are you using?


#3

Hi @daschl, I am using Nodejs.


#4

@brett19 can you share an example of how to get the total rows in node? I checked http://developer.couchbase.com/documentation/server/4.0/sdks/node-2.0/view-queries.html but we might need to add this there too.


#5

Hi @daschl,
And another question, can Couchbase View descend by value? I check it only descend by key.
Thank you.


#6

@Sonrobby no it is not possible to sort by value at all with views. For that you need N1QL.