MISSION 256

Querying SQLite from Python

Learn how to query a SQLite database from Python.

Objectives

  • How to run SQL queries using sqlite3 in Python.
  • How to work with cursors and tuples.

Mission Outline

1. Overview
2. Introduction to the Data
3. Connecting to the Database
4. Introduction to Cursor Objects and Tuples
5. Working With Sequences of Values as Tuples
6. Creating a Cursor and Running a Query
7. Execute as a Shortcut for Running a Query
8. Fetching a Specific Number of Results
9. Closing the Database Connection
10. Practice
11. Next Steps
12. Takeaways

sql-fundamentals

Course Info:

Beginner

The median completion time for this course is 6.3 hours. View Details

This course requires a basic subscription and includes five missions and one guided project.  It is the 11th course in the Data Analyst in Python path and the Data Scientist in Python path.

START LEARNING FREE

Take a Look Inside