In today’s world, data is prevalent in every aspect of our lives as human beings. Data is constantly being created, organized, and stored. With all this data being transferred and exchanged around the world, it is important to have an efficient and organized method to storing this data. This is where databases come in. Databases offer improved efficiency and versatility, they allow categorization and structuring of available data, and they allow multi-user access, creating an organized work environment and newer and better ways to manage data.
As a full stack developer it is very essential to understand how to structure, build, and query your own database.
In this week you’re going to learn how to create a database to persist data for your program.
- Persistence: you’ll recall is the ability to remember data even after the server is restarted, and most applications require it.
- Explain what the term database means
- Why to use database
- Explain what is DBMS
- Relational & Non-relational databases
What is Database
For example, consider your account on social hackers academy. Where are your username and password stored? Or perhaps where all of your assignments progress might be fetched from? How does the application determine what topics are shown to you every time you log on? These operations are handled by a database.
So what is database?
Database, also called electronic database, any collection of data, or information, that is specially organized for rapid search and retrieval by a computer.
Databases are structured to facilitate the storage, retrieval, modification, and deletion of data in conjunction with various data-processing operations.
A database is usually controlled by a DataBase Management System (DBMS).
Together, the data and the DBMS, along with the applications that are associated with them, are referred to as a database system,
often shortened to just database.
Why do we need to use Database:
but you should notice, that whenever we close the server and re-run our application again, nothing is been saved, for that we will use databases to achieve the Persistence for our data; which means the ability to remember data even after the server is restarted, and most applications require it.
Data Base Management System – DBMS
A database typically requires a comprehensive database software program known as a Database Management System (DBMS).
A DBMS serves as an interface(API) between the database and its end users or programs, allowing users to retrieve, update, and manage how the information is organized and optimized.
What are the different types of Database Management Systems?
There are nearly a dozen different types of databases in use today.And each handles data and scaling in different manners.Some of the more commonly used types of database management system (DBMS) include the following:
- Database management systems that structure data in table form, with predefined relationships between tables, and a Structured Query Language (SQL) for reading and writing data.
- Database management systems that structure data in JSON-like documents, with a document-oriented query language like MongoDB Query Language (MQL)for reading and writing portions or all of documents.
- database management systems that organize data by column, for certain high-performance and disk-heavy use cases.
NoSQL database management systems store information in different ways. For example:
Data can be stored in a structured document, similar to
Data can be in a key-value format which maps a single attribute (its “key”) to its value. Redis and Riak KV are some examples, and they’re typically used for simple one-to-one relationships, like associating users with preferences, caching, or keeping track with a counter.
A graph datastore uses nodes to represent objects and edges to describe the relationship between them. Neo4j is one such example.