Can we run N1ql in Java Android and Objective C on Couchbase Lite eco system without Query builder API?


#1

Is there an Option to run N1ql inside Couchbase Lite eco system (Java Android and Objective C/Swift ) without Query builder API?
For a Cordova Mobile application, I would like to prepare the query from Javascript side and pass to Native library so that the querying logic can be kept in Javascript part of the application on which developers spend more time.


#2

At this time, we do not have the provision to run N1QL queries within Couchbase Lite. We are evaluating options for hybrid platform support .
In the meantime, check out this blog post on creating a Cordova plugin for CBL 2.x and direct links to tutorials for iOS and Android . I understand that querying can be a bit tricky but if you have purpose-built query APIs instead of a generic one , then it should not be that tedious to do it on the native side and expose a JS API.


Can anyone share sample Cordova github project which inserts JSON object as a document to Couchbase Lite