Rajesh Khadka
Rajesh khadka

Rajesh khadka

All the things you need to know about database 📰🚀

All the things you need to know about database 📰🚀

Rajesh Khadka's photo
Rajesh Khadka
·Aug 3, 2022·

3 min read

Subscribe to my newsletter and never miss my upcoming articles

Play this article

Introduction

A database is an organized collection of structured information, or data, typically stored electronically in a computer system.

Oh. common it's just a definition, nothing more to do with this. Let's give a few minutes to understand database much more practically and lets feel it .. 🔥

  • Let's take an example, you just opened Facebook and you wanted to make a post saying , "Hey !! developers'' and if it gets posted successfully,

Where does that post go and stay ?

  • You upload videos to the YouTube, and again if its uploaded successfully,

where does that information regarding video goes and saved ?

These all of the questions has a single answer "Database".


Disclaimer ⚠

This blog is totally for beginners, so my request 🙏 for experienced developer please, don't leave a comment saying, "This is the bare minimum and basics" 😂


Types of database 📰

If I'm not wrong, you have frequently heard about sequel and non sequel databases. People are really making these things super complex for the beginners. So, let's break these terms into the easiest one !!

Okay, again lets pick up an example of “uploading YouTube video”. And we all know that a video has a certain attribute i.e. id ,Title, Description, likes, comments, uploaded date and many more. Let's think for a while, How do these actually get visible as a piece of data ? And here where a sequel and non sequel databases comes in.

The above attributes looks like in sequel database :

image.png Here, we can say that, the sequel database stores the data in the table as rows and columns. Some popular sequel databases are :

  • MySQL
  • Oracle
  • Postgrace

And again, these same attributes looks like in non-sequel database :

{
    id : _2525252155,
    title  : "All the things You need to know about DB to get started",
    description :  "Description goes here !",
    likes : 1250,
    comments : "Nice Video ! ❤ "
};

It also may have some nested data :

{
    ....,
    comments : ["Nice blog", "Amazing" ]
};

Here, we can say that the non-sequel database stores the data in the JSON or BSON format . Some popular non-sequel databases are :

  • MongoDb
  • Firebase

What to use for your Next Project ?

Okay ! It's not a simple or too much easy to say use "MySQL" (sequel) or "MongoDB" (non-sequel). The answer is It depends ! in most of the cases, Choosing the database is based on what type of project you are working on. If it is just a simple todo app feel free choose any db you like the most without thinking about it. But if the project is more than todo app, serves a millions of users then My suggestion would be use Non-sequel db's because they are more scalable and flexible .

 
Share this