DATA MODELLING

Neha Rajesh

4 min read

Introduction

Data modelling is the process of creating a model for the data to be stored in a database. This is a conceptual representation of data and the relationship and rules between different data and objects. Simply put, data modelling helps to build conceptual models and set a relationship between data items.

Data modelling helps visually represent data and it's relationships. They ensure consistency in naming, default values, semantics and security while maintaining the quality of data.

What is a Data Model?

A Data Model is an abstract model that organizes data. It emphasizes on what data is needed and how it should be organized, instead of what operations will be performed on it.

Data Modelling Techniques

There are two types of Data Modelling Techniques:

Why should we model data?

Types of Data Models

So, How do you create a Data Model?

In javascript, you create data models by creating objects. The key will be the field and value will hold whatever value you want to store in the field.

For example, a basic products data model will look like this :

   const products = {
      id: 1234, //number or id
      name: "Product Name", //string
      description: "Product Description", //string
      brand: "Product Brand", //string
      price: 12.34, //number
   }

The key is the field, value is the value we want the field to have and in comments is the data type of the values this field can store.

We always create data models as objects because this helps keep the database sizable.

Conclusion

Data modelling is the process of developing models for the data to be stored in a database. These ensure consistency in naming, default values, semantics and security while ensuring quality of data. Data modelling helps to define relational tables, primary and foreign keys and stored procedures. The main goal of designing a database is to make certain that data objects offered are represented accurately. The biggest drawback is that even small changes made in structure require modification in the entire application.