Model Your Data
Data modeling (or in other words, designing your database schemas) is the process of conceptualizing and visualizing how data will be stored and used by identifying the patterns used to access data and the types of queries to be performed within business operations.
This page first explains the ScalarDB data model and then describes how to design your database schemas based on the data model.
ScalarDB data model
ScalarDB's data model is an extended key-value model inspired by the Bigtable data model. It is similar to the relational model but differs in several ways, as described below. The data model is chosen to abstract various databases, such as relational databases, NoSQL databases, and NewSQL databases.
The following diagram shows an example of ScalarDB tables, each of which is a collection of records. This section first explains what objects, such as tables and records, ScalarDB defines and then describes how to locate the records.
Objects in ScalarDB
The ScalarDB data model has several objects.
Namespace
A namespace is a collection of tables analogous to an SQL namespace or database.
Table
A table is a collection of partitions. A namespace most often contains one or more tables, each identified by a name.
Partition
A partition is a collection of records and a unit of distribution to nodes, whether logical or physical. Therefore, records within the same partition are placed in the same node. ScalarDB assumes multiple partitions are distributed by hashing.