A data model is an abstract model that helps to organize data elements and standardize how they are related. It reveals relationships between different real-world objects. It also refers to an output of data modeling: a process of creating visual diagrams using different components to represent the data. Show
To review the basics of data models as well as learn about the process of building data models and how GoodData supports this process, read our article “What Is a Data Model?” In this article, we will focus on examples of data models, paying special attention to today's most used types — relational and dimensional data models — in order to highlight their use cases and benefits. What Is a Relational Data Model?A relational data model is an approach to creating relational databases in order to manage data logically by its structure and language consistency. In this model, data is represented in the form of two-dimensional tables. Each table represents a relation of data values based on real-world objects, consisting of columns and rows known as attributes and tuples. Relational data models prioritize the maintenance of data integrity. This practice ensures data protection and consistency which are critical aspects of data model design, its implementation, and its future usage for storing, processing, and retrieving data. How to Build a Relational Data ModelWhile building a relational data model, you can define all types of relationships between relations representing real-world objects, such as one-to-one, one-to-many, and many-to-many. Many-to-many relationships require decomposition, which refers to a process of dividing a relationship into two or more sub-relations. This process creates an additional table with two one-to-many sub-relationships connected to the main tables. The connections between tables in relational databases are made by relational references using primary and foreign keys. There are three types of keys in a relational data model:
Image credit: Guru99 Another essential step of building relational data models is normalization. Normalization is a process of analyzing relation schemas based on functional dependencies and relational references in order to decrease redundancy and avoid anomalies. There are several normal forms (NF) but the first three are the most common:
What Is a Dimensional Data Model?A dimensional data model is a type of database used for data warehousing and online analytical processing. This model is a part of the core architectural foundation of developing highly optimized and effective data warehouses in order to create useful analytics. It provides users with denormalized structures for accessing data from a data warehouse. How To Build a Dimensional Data ModelA dimensional data model consists of two types of tables: fact tables and dimensional tables. A fact table stores numeric information about different business measures. Dimensional tables, also known as dimensions, store attributes used to describe objects in a fact table. A dimension is a set of reference information about a measurable event in data warehousing. Primary and foreign keys connect fact tables and dimensions as they do in relational data models. You can build your dimensional data model based on different schemas: star, snowflake, or galaxy. In the center of every star schema is a fact table containing measures and foreign keys of connected dimensions. A snowflake schema extends a star schema and contains some additional dimensions. Dimensional tables are standardized and normalized, resulting in dimensions split into extra tables which are reconnected in hierarchical order. A galaxy schema is similar to the above mentioned schemas, but it has more than one fact table. It usually contains at least two fact tables from two separated dimensional models which share the same dimensional table. To design dimensional data models, denormalization is the best approach. Denormalization is a process which is usually applied on top of a normalized database/data model. It is done by adding data duplicates or grouping data. Denormalization is necessary to increase performance and support scalability due to the fact that this data model deals with a large number of read operations/queries for analytics purposes. Relational Data Models vs. Dimensional Data ModelsRelational data models differ from dimensional data models in many ways: the process of data modeling, use cases, benefits, and drawbacks. Importance and Use CasesRelational data models store present data. Their primary purpose is to model relational databases, which are especially useful to establishing and managing an overview of current data. Relational data models can support operations for various industries. Banks can use them to store sensitive data about customers' accounts, just as vendors can use them to store available items on their e-commerce store. Relational databases are used to read and write data. Dimensional data models are designed to store historical data for analytics purposes and create data warehouses. You can use them to store data (regardless of the department or use case it's related to) that was gained by tracking different processes, such as products sold, numbers of visitors, etc. Data warehouses created in dimensional data models are mostly used to read data. Advantages and Disadvantages of a Relational Data ModelAdvantages:
Disadvantages:
Advantages and Disadvantages of a Dimensional Data ModelAdvantages:
Disadvantages:
Data Models in GoodDataGoodData provides users with an analytical platform and enables them to connect data from multiple sources, create various metrics, and design dashboards to track business performance. With GoodData, you can create dimensional data models that meet your needs and preferences. By creating dimensional data models, you can design a database to store various data in a centralized place, then design your data in a way that works best for you. It allows and supports faster data retrieval and helps create valuable reports to improve and facilitate future business decision-making. Additionally, GoodData supports dimensional models based on any kind of dimensional schema. You can choose from a star, galaxy, or snowflake schema as we mentioned above. Ready To Get Started?Try out our GoodData.CN Community Edition and create data models to track your business processes. Connect sources, create metrics, and design dashboards according to your requirements. Additionally, don't forget to complete this GoodData University Course to learn more about GoodData's solution and read our documentation. What is a 3 dimensional database?As the name suggests, multidimensional databases contain arrays of 3 or more dimensions. In a two dimensional database you have rows and columns, represented by X and Y. In a multidimensional database, you have X, Y, Z, etc. depending on the number of dimensions in your data.
Are relational databases twoRelational databases organize data in two dimensions with rows and columns, and use Structured Query Language (SQL) as their primary language. Relational databases make it easy to sort and find information, which helps organizations make business decisions efficiently and minimize costs.
What is the difference between a relational database and a dimensional database?Relational databases are used to read and write data. Dimensional data models are designed to store historical data for analytics purposes and create data warehouses.
How does the multidimensional database store data?The data in multidimensional databases is stored in a data cube format. This means that data can be seen and understood from many dimensions and perspectives.
|