Document design

Document design is a more involved activity than key design. There are far more variables to consider when creating a document's schema. Some of these factors are specific to Couchbase. Others are generally applicable to document databases.

Denormalization

When designing a relational system, you typically start with a highly denormalized logical view of your entities. That view is then normalized into a physical model where the data is spread across several tables in an effort to minimize any possible data redundancy.

Similarly, you'll likely start your document design by creating a denormalized, logical model. With this approach, your design first considers the most complete document that your domain demands. For example, if you ...

Get Couchbase Essentials now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.