Hi, I’m curious about n1ql and how it fits inside couchbase, my first thought was it used views from behind and was only a sugar for the “tradicional couchbase way” but it’s hasn’t totally sense because how couchbase would know how many views must create?..for example
SELECT name FROM contacts ORDER BY age LIMIT 3
this would require create a view where the key will be the name…when I use this query couchbase creates the view from behind and on the fly?..is this efficient?..
other example very interesting is using the sql AND statement inside n1ql…normally this would require create a collated view with arrays as keys [tomato,7] …in the n1ql this is transparent and pretty clear…couchbase create this view?..or this use other mechanism?
Other interesting stuff is than now you can access to a specific part in the json
SELECT children.fname AS cname
this mean than we can change the way how we create our “schemas”, normally is recommended separate the habitual accessed information from the not one
user1::data (not needed so frecuently)
user1::Articles (frecuenty accessed)
now…with the n1ql approach would be possible keep all the data inside the same document??..how this works??..
what about change information, would be possible not only retreived info and could change a specific field in the document, avoiding retreive all the document, change in the client side and send again?? (I’m pretty sure than it will not possible but I can’t resist the tentation of make the question :D)…
I feel than practically couchbase would be 2 db’s inside one (and it’s not about couchbdb and membase) with 2 totally different ways for working and if n1ql hasn’t limitations this means than the old way would become obsolete…the couchbase idea is than in the future we use n1ql abstraction and remove the actual “tricks” from handling data??
- Is possible use it with the actual sdks, for example the java sdk ??
- what about the performance?..
thanks so much and
thanks so much I really appreciate the effort you has placed in couchbase