Explore building indexes in Couchbase, and compare Oracle vs. Couchbase index features and approaches to consistency. See how to create and tune a Couchbase index using a visual query plan.
index creation and tuning is a significant part … of the development process. … Let's take a look at how much you already know … about how this works in Couchbase. … Index creation in Couchbase is analogous to Oracle. … You create an index with a specified name … on a specified bucket not table. … For a list of one or more fields, not columns … and it's of course automatically maintained until removed. … Which can be done with a drop index statement … specifying the bucket name and the index name. … Any number of filters can be added to an index … to narrow the range of documents to be indexed. … Naturally these filters then become required … for a query to use the index. … Because a filter narrows the total range … of documents indexed. … However the sequence of filters in your query … does not matter, and when needed the query planner … will try to fall back on less precise indexes … that apply, including a primary index, … rather than allow a query to fail. … To generate the plan document for any query …
This course was created by Couchbase Learning Services. We are honored to host this training in our library.