Couchbase Questions: Couchbase views

Have a Question? Get it answered by our community

joaojeronimo's picture
Asked 3 weeks 2 days ago
Latest activity 3 weeks 1 day ago

Is there any way to manipulate the stale flag ?

I was running some tests, inserting a bunch of data and retrieving it right after with a N1QL query, and after I created an index for a field, querying by that field right after inserting the document was not working. I dug a bit and found some information about the stale flag, and thought that...

pappu_pandit's picture
Asked 1 month 5 days ago

View design


I want to write a view that can extract array object members based on array object members value.

For example, I have a document that has this structure written to it:

public class ABC{

public class DoorData

isanfulia's picture
Asked 1 month 2 weeks ago

Querying Views using a POST request instead of GET (key limit)

Hi all,

I was trying to query view with many keys(around 20K) using the Java api but this results in exception. The reason I think is because the query is fired as a GET request which has the limit on the number of characters in the URL. Is there a way to do a POST request on view using...

Hao Liu's picture
Asked 2 months 4 days ago
Latest activity 1 month 3 weeks ago

Does CouchbaseClient.Query take a snapshot of the data?

Say I have a view with a reduce function that gives count of documents, and I get a ViewResponse by calling client.Query() with includeDocs set to true. Then I iterate the ViewResponse and use the count got from the view. Can I iterate the same ViewResponse object again sometime later to stamp a...

opic's picture
Asked 2 months 4 days ago
Latest activity 2 months 3 days ago

Building views in the background with Couchbase Lite


When you have a large database (let's say 10 000 documents) building views can be very long. Could we use a type of background view build mechanism ? Would this be available for the PhoneGap connector ?

The CouchDB REST Api specifies that on a query you could use the :...

ohassidi's picture
Asked 3 months 2 days ago

Creating Views using command line

Is that possible?

jasonmartens's picture
Asked 3 months 2 days ago

View ordering with range

I would like to create a view that is returned in a specific order (for example, by the doc id or a datetime field), but can be filtered by a key range. For example, suppose I had a lot of documents like this:

jbroughton's picture
Asked 3 months 2 weeks ago

Querying a view count issue


I have a query I am running and its returning some strange results:

In my view the key is set up as [identifier, type]

in my query I am passing:
keys: [[identifier, 'receipt'],
[identifier, 'open'],
[identifier, 'help'],...

levonio99's picture
Asked 4 months 2 weeks ago
Latest activity 4 months 2 weeks ago

Sorting asc vs. desc performance in views and N1QL


We know that the views sort data in ascending order. Since N1QL uses views behind the scenes, we assume that ORDER BY in asc is performant. How does N1QL handle ORDER BY desc? Is there a difference in performance?

For example in SQL relational database when an index is...

zbintliff's picture
Asked 5 months 2 days ago
Latest activity 4 months 3 weeks ago

Multiple Views on Design Document

I'm using couchbase for proof of concepts and such. I am reading about views and design documents and understand them (I think). So far whenever I wanted to create a new view I created a new document as well. Is there any benefit or drawback for putting multiple views on the same design...