Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python SQLAlchemy Basics Introduction to SQLAlchemy Creating a Model

2 Answers

Steven Parker
Steven Parker
231,275 Points

A generic "engine" is just a program, and in this case it's what provides the core interface to the database.

Sergio Andrés Herrera Velásquez
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Sergio Andrés Herrera Velásquez
Python Development Techdegree Graduate 13,645 Points

As per the documentation

This object acts as a central source of connections to a particular database, providing both a factory as well as a holding space called a connection pool for these database connections. The engine is typically a global object created just once for a particular database server, and is configured using a URL string which will describe how it should connect to the database host or backend.

It means that the engine is how we connect to each database under the hood and the string provided is telling it -under the hood- what database we are using