Mô tả

Master PostgreSQL and use it in your Python apps!

Python and PostgreSQL are two of the most in-demand skills in the world. After completing this course, you'll be confident in adding both to your resume/CV.

Everything you'll learn in this course is relevant to other database systems too, like MySQL, Microsoft SQL Server, or Oracle.

With this course, you'll master PostgreSQL and how to work with it from Python. If you use Python and you want to augment your skills with a database, you'll love this course!


You will:

  • Work with different types of databases (in-memory, SQLite, and PostgreSQL), and understand when to use each in your Python apps.

  • Build a programming journal project to add a SQLite database to your Python application.

  • Improve a database design incrementally so you're not bound by your initial design.

  • Model different relationships with PostgreSQL, including one-to-many and many-to-many.

  • Reduce errors by applying database changes using database migrations with Python and alembic.

  • Build a polling app to learn about advanced data analysis with GROUP BY, PostgreSQL window functions, and nested queries.

  • Work with dates and times in PostgreSQL, and avoid common timezone pitfalls.

  • Structure Python apps like a professional, to make development much easier.

  • Produce data analysis reports and charts using matplotlib with PostgreSQL data.


You'll also tackle advanced PostgreSQL topics, such as:

  • User-Defined Functions

  • Stored Procedures

  • Locking

  • Async database connections


As you can see, you're going to learn a lot!

But this is a no-nonsense, no-frills course. We have planned, crafted, and edited every lecture to be concise and compact. No time wasted, so you can master PostgreSQL in record time.

We've created dozens of diagrams to explain database concepts, as well as code-along videos. But you won't just be watching me code! You'll develop the projects yourself first, to gain hands-on experience and master PostgreSQL.

Also, throughout the course, I provide data sets with challenges and exercises for you to practice what you've learned.

I've been teaching and helping students online for over 8 years, and this course is the culmination of my teaching experience. I know how to help you understand concepts fully and quickly, in the best way for you.


When you complete this course you'll be able to:

  • Extend your Python applications with database functionality using PostgreSQL.

  • Answer complex questions using data and generate reports.

  • List PostgreSQL as one of your strongest skills.


Check out the free preview videos for more information and to try out the course!

I'll see you on the inside!

Bạn sẽ học được gì

How to leverage the power of databases (in-memory, SQLite, and PostgreSQL) to upgrade your Python applications

Prevent common pitfalls: avoid SQL injection attacks, store database credentials securely, and optimize the performance of your applications

Understand how databases work and how to take advantage of their features from the ground up, by building multiple projects

This is a no-nonsense, no-frills course on fully mastering PostgreSQL and how to use it effective within and outside of your Python apps

Learn how to work with dates and times effectively in Python applications

Produce engaging charts, graphs, and reports using database data

Yêu cầu

  • Foundational Python knowledge is required (a Python refresher is provided), as the course focuses on using PostgreSQL with Python
  • A Python editor or IDE, such as Visual Studio Code or PyCharm
  • You don't need to install anything more for this course, everything we do is on the cloud (although guidance to do it locally is also provided)

Nội dung khoá học

10 sections

Introduction

3 lectures
Welcome to this course!
02:31
Initial setup (for newer Pythonistas)
00:36
Get the complete e-book here
00:09

A Full Python Refresher

41 lectures
Introduction to this section
01:01
Access the code for this section here
00:24
Variables in Python
08:26
String formatting in Python
06:26
Getting user input
05:16
Writing our first Python app
03:19
Lists, tuples and sets
06:31
Advanced set operations
04:39
Booleans in Python
04:59
If statements
08:17
The "in" keyword in Python
02:02
If statements with the "in" keyword
08:18
Loops in Python
11:07
List comprehensions in Python
07:24
Dictionaries
08:31
Destructuring variables
08:28
Functions in Python
10:41
Function arguments and parameters
07:40
Default parameter values
03:54
Functions returning values
07:19
Lambda functions in Python
07:52
Dictionary comprehensions
04:01
Unpacking arguments
10:24
Unpacking keyword arguments
08:44
Object-Oriented Programming in Python
15:52
Magic methods: _str_ and _repr_
06:25
@classmethod and @staticmethod
14:03
Class inheritance
08:32
Class composition
06:08
Type hinting in Python 3.5+
05:08
Imports in Python
09:33
Relative imports in Python
08:52
Errors in Python
12:47
Custom error classes
05:04
First-class functions
07:52
Simple decorators in Python
07:12
The 'at' syntax for decorators
03:32
Decorating functions with parameters
02:24
Decorators with parameters
04:50
Mutability in Python
06:03
Mutable default parameters (and why they're a bad idea)
04:27

Build a Programming Journal with Python & SQL

22 lectures
Overview of the project
02:30
Creating our user menu
06:22
What is SQL?
05:42
Using Python lists as an in-memory database
12:27
A SQLite data viewer
05:16
CREATE TABLE: new tables with SQL
04:15
How to write comments in SQL
00:27
CREATE TABLE exercises
00:32
How to connect to a SQLite database with Python
07:16
Connecting to SQLite in our app
03:23
What is a cursor?
05:11
INSERT INTO: add data to a table
04:26
INSERT INTO exercises
00:55
How to insert data into SQLite with Python
07:15
SELECT: retrieve data from a table
02:40
SELECT exercises
00:36
Retrieving results from a cursor
07:38
WHERE: search with SQL
07:03
WHERE exercises
00:36
DROP TABLE: deleting entire tables
01:38
DROP TABLE exercise
00:08
What is a SQL injection attack?
03:37

A Movie Watchlist App with Python & SQL

26 lectures
Overview of the project
02:08
Three development stages of our project
04:15
Our starting code for this project
01:25
Queries we'll need for the project to begin with
05:06
Write the database.py file
07:01
UPDATE: changing data with SQL
03:35
UPDATE exercises
00:55
Write our user menu and functions
11:45
Watched movies: second approach
01:01
DELETE FROM: removing rows with SQL
02:15
DELETE FROM exercises
00:38
Stage 2: watching movies
07:56
Relational data: primary and foreign keys
04:15
Relational data exercise
00:20
Watched movies: final approach
02:52
Stage 3: adding new watched movies
08:49
Auto-incrementing row IDs
03:41
Auto-incrementing exercise
00:34
JOIN: access two tables at once with SQL
03:16
Use JOINs to retrieve the movies a user has watched
08:52
Types of JOINs with examples
00:23
ORDER BY: sort the returned table
01:51
LIMIT: getting a certain number of rows
01:05
LIKE: flexible searching
06:50
What is an index in SQL?
04:46
Adding an index to our table for more efficient searching
04:27

Introduction to PostgreSQL: Migrating our App

8 lectures
SQLite vs. PostgreSQL
04:27
How to install PostgreSQL
04:47
How to run and access PostgreSQL
03:57
psycopg2 vs psycopg2-binary
11:16
How to store (and not store!) sensitive information in your code
08:21
Psycopg2 cursors and query parameters
04:55
Auto-incrementing columns: SEQUENCE and SERIAL in PostgreSQL
01:55
Our changed code, and finding differences between files
01:30

Building a Poll App & Advanced SQL

17 lectures
Overview of the project
03:06
What is ACID?
03:57
Essential queries we'll need for this project
09:38
RETURNING data from modified rows
06:34
Nested queries: getting the latest poll
06:16
SQL built-in functions
04:20
GROUP BY and calculating vote percentages
12:13
PostgreSQL window functions
05:45
PostgreSQL window functions (part 2)
05:06
How to use ORDER BY with window functions
04:14
How to use PARTITION with window functions
04:18
SQL DISTINCT and DISTINCT ON
06:33
The SQL HAVING clause
01:14
SQL VIEW: virtual tables
09:52
How to read the PostgreSQL documentation
08:09
Adding type hinting to our application
07:15
Extra: check constraints in PostgreSQL
00:39

Working with dates and times

13 lectures
How to separate our database entities into models
11:23
Creating our Option model class
04:15
Changes needed in database.py
07:40
Changes needed in app.py
11:50
What is connection pooling?
03:56
How to create a connection pool with psycopg2
05:51
Reduce pooling duplication with context managers
05:03
Reduce cursor creation duplication with context managers
02:57
The Python datetime module
04:40
How to calculate new dates with timedelta
03:04
How to handle timezones with pytz
10:24
How to save dates to PostgreSQL
08:25
Add the vote date to our polling app
08:28

Python and Advanced PostgreSQL with psycopg2

8 lectures
Composite primary keys
02:58
User-defined functions in PostgreSQL
09:15
Composite types and sets in functions
07:46
Stored procedures in PostgreSQL
05:25
Connections vs transactions in psycopg2
03:28
Locking in PostgreSQL
08:56
Asynchronous psycopg2
01:39
SQL string composition with psycopg2
04:40

Charting data from our tables using matplotlib

16 lectures
Overview: creating graphs from poll data
02:28
How to install matplotlib
00:24
How to draw a line graph with matplotlib
04:35
Matplotlib backends
00:32
Matplotlib figures, axes, and plots
03:55
The Object-Oriented Approach with matplotlib
03:25
How to add multiple subplots to a figure
04:39
How to draw a pie chart with matplotlib
13:27
How to draw a bar chart with matplotlib
05:25
How to adjust the size of a matplotlib plot
03:25
How to adjust the x axis tick labels so they fit in the screen
05:11
How to draw a stacked bar chart with matplotlib
06:20
How to create a legend from your graphed data
02:44
How to export an image with matplotlib
07:42
How to create one document with multiple matplotlib plots
02:45
How to create a custom legend with matplotlib
03:02

Bonus Section

1 lectures
Bonus Lecture
00:36

Đánh giá của học viên

Chưa có đánh giá
Course Rating
5
0%
4
0%
3
0%
2
0%
1
0%

Bình luận khách hàng

Viết Bình Luận

Bạn đánh giá khoá học này thế nào?

image

Đăng ký get khoá học Udemy - Unica - Gitiho giá chỉ 50k!

Get khoá học giá rẻ ngay trước khi bị fix.