...

/

Database Connection using SQLAlchemy

Database Connection using SQLAlchemy

In this lesson, we will be exploring how to create a database connection in your Flask application by using SQLAlchemy.

Introduction #

Finally, in this chapter, we will learn to handle the data using a database. Up until now, we have been using some data structures like a dictionary, but in a real-world application, this approach is rarely, if ever, used. We will be using an SQL database and an object relation mapper to manipulate that database inside Flask.

πŸ“Œ What is an ORM or object relation mapper? #

An ORM makes writing SQL queries easier for a programmer. It enables us to write queries in an object-oriented language, and then ...