Simple play icon Course

Modify Data in Couchbase 6 Using N1QL

by Kishan Iyer

This course covers different ways to alter document data in Couchbase using the N1QL query language. It explores the queries used to add new data, modify existing data, and remove unwanted documents.

What you'll learn

Are you looking for different ways to alter document data in Couchbase? In this course, Modify Data in Couchbase Using N1QL, we look at different ways in which document data can be added to Couchbase, modified, and also removed using the N1QL query language. First, you will cover the different kinds of statements which N1QL provides in order to perform data modifications. You then delve into the use of INSERT statements to add one or more documents to Couchbase buckets and examine the role-based access control feature of Couchbase, specifically, the assignment of permissions to users to run N1QL queries performing INSERT operations. Next, with the addition of entire documents, you will discover how individual attributes can be added to, modified or removed from existing documents using the UPDATE statement. You will also cover the use of UPSERT statements which are a combination of INSERT and UPDATE statements. You will also explore the use of DELETE statements in order to remove documents which are no longer required. Finally, once you are familiar familiar with different ways to modify data, you will cover the use of MERGE statements to define which data needs to be added, modified or removed based on the results of a join operation. Once you are done with this course, you will have the skills required to perform any kind of data modification on your Couchbase document data using the N1QL query language.

About the author

I have a Masters in Computer Science from Columbia University and have worked previously as a developer and DevOps engineer. I now work at Loonycorn which is a studio for high-quality video content. My interests lie in the broad categories of Big Data, ML and Cloud.

Ready to upskill? Get started