Downloading & installing N1QL

awesome, glad it works now!

I figured I’d post this here instead of starting a new thread.
I’m also having trouble getting N1QL to work in our project. It works fine in the CBQ client.

In our project any N1QL query returns 0 rows with content ‘index out of range’ - it does not throw any error.

This goes for the same ultra simple requests that work with CBQ

We are using Xamarin Studio with couchbase 4.0 and thecouchbase C#.Net SDK (v. 2.1.4) with the .Net Framework 4.5 // all that on windows 7. Our cluster has 3 nodes, one of them is assigned to Data, Index, and Query.

Here is a sample code of what we’re doing in C#:

string query = "SELECT c FROM DataBoard as c";
var result = CouchbaseManager.Bucket.Query<dynamic>(query);
foreach (var row in result.Rows) 
{   […]   }

If anyone’s run across similar behavior or has an Idea on what to try…

Couchbase 4.0 hasn’t been released yet, so you must mean 4.0 Beta? I think the best thing to try at the moment would be to turn up the log level to see if you can spot what’s happening and/or give us some more info. I’ve also asked someone else to have a look here.

This is likely the problem; 2.1.4 only supports N1QL queries on a single node. This will be resolved in 2.2.0 to be released in October 2015. More info in this blog post: The Couchbase .NET SDK 2.1.4 is now Available! - The Couchbase Blog

-Jeff

Hi Jeff,

Is it possible to clarify? I read a couple of weeks ago something of the sort that had pushed me to switch all nodes assigned to Data, Index and Query when trying to get N1QL to work. I switched them back to how I’m guessing it’s supposed to be, with a single node handling Index/Query.

From what you are saying and from what I’ve just read on your link; Neither approach described above would work, but only on a Cluster with a single node (and that node having to be assigned to all 3)?

If that’s the case, it’s a bit of a bummer but I guess we’ll have to wait until october…

Either way, thanks!

@spcmnky -

Yes, currently N1QL and MDS only work on a single node with 2.1.4. I haven’t tried yet, but it would probably work on a cluster if the query service is configured on each node of the cluster.

The work for this will be done before October, so once it’s merged it will be possible to clone the repo in github and build it yourself (for testing only). Additionally, I may be able to provide a NuGet package of the SDK with this working about the same time, once again this will not be an official release, so it will not be supported and I wouldn’t use it in production.

-Jeff

Ok that clears it up,

We’ll just test out N1QL with a single node cluster for now.
Thanks!