DEV Community

Cover image for What is Querying a Database? Everything You Need to Know
Karl Esi
Karl Esi

Posted on • Updated on

What is Querying a Database? Everything You Need to Know

So, one of the most common things that you are going to be doing is our queries.

So, a database query is a request that is made to the database management system for specific information.

So, you will hear the word query thrown a lot. In general, a query is, you are just asking a database management system to give you some information.

So, as a database structure becomes more and more complex, it becomes more difficult to get more specific pieces of information that we want.

And if you have a very complex database layout or schema, then getting a specific piece of information can be a little bit tricky. And that is why we write database queries.

So, you could write a very complex database query which in a lot of ways is like a program, if you have ever used a programming language before, and that query will then instruct the relational database management system to grab a specific piece or specific pieces of information from the database.

So, a good way to think of a query is, that it is kind of like a Google search. So, I go on Google and I would generally type in specific information that I want, then Google would give me the information that matches that search query.

That is a lot like a database query. Except, with a database query, we are not going to write the query in English like we would with Google.

So, I can go up to my Google search bar, and I could type something in English, Spanish, or whatever language you speak.

But for a relational database management system, we have to write our queries using either SQL or a specific language that is meant for that database management system.

Happy Coding!
Karl 🤛

P.S. This is a small sneak preview of my flagship course, The Art of Web Development. 14 Chapters and 111 Lessons that will help you become a Full-Stack Web Developer with just ONE course (even if you're just starting or don't have an idea).

Top comments (0)