Cademy logoCademy Marketplace

Course Images

The Complete Python and PostgreSQL Developer Course

The Complete Python and PostgreSQL Developer Course

  • 30 Day Money Back Guarantee
  • Completion Certificate
  • 24/7 Technical Support

Highlights

  • On-Demand course

  • 21 hours 50 minutes

  • All levels

Description

Build 9 projects to master 2 essential and modern technologies: Python and PostgreSQL

Ever wanted to learn one of the most popular programming languages on the planet? Why not learn two of the most popular at the same time? Python and SQL are widely used by small to large technology companies thanks to their powerful, yet extremely flexible features. While Python is used in the industry for embedded software, web development, desktop applications, and mobile apps, PostgreSQL allows your applications to become even more powerful by storing, retrieving, and filtering through large datasets easily. This course is your one-stop-shop for everything Python and PostgreSQL. You'll advance from an absolute Python and PostgreSQL beginner to an experienced software developer. Get ready to transform your world and become a super-confident app developer! All the code files are placed at https://github.com/PacktPublishing/The-Complete-Python-and-PostgreSQL-Developer-Course

What You Will Learn

Extend Python applications by using professional data storage - PostgreSQL
Understand advanced concepts, such as data structures and algorithms, that are extremely useful in jobs and interviews

Audience

If you're a complete beginner to programming and Python, this course will provides concise explanations with hands-on projects. Intermediate programmers will be able to fly through the first couple of sections and quickly learn about PostgreSQL and advanced Python concepts. This course is likely not for advanced programmers, although it has a lot of useful information that will serve as a reference!

Approach

This course is designed in such a way that each section covers a new scenario with a step-by-step approach to help you learn and understand relevant concepts.

Key Features

Gain comprehensive understanding of software and programming with Python * Create basic beginner-level applications to advanced engaging applications using Python

Github Repo

https://github.com/packtpublishing/the-complete-python-and-postgresql-developer-course

Course Outline

1. Installing Python

1. Introduction

In this first video we introduce the course and what we are going to be learning!

2. Installing Python on Windows

Learn how to install Python on Windows. Remember to add Python to the PATH!

3. Installing Python on Mac

Learn how to install Python on Mac. It's very straightforward.


2. Python 101

1. The Python interactive shell (IDLE)

The Python Shell (also known as IDLE) is ideal for learning Python. It lets you run Python code interactively.

2. Numbers and Strings in Python

Learn about numbers and strings in Python, two key data types.

3. Variables in Python

Learn how to create variables in Python.

4. The str() method to convert to Strings

Learn about the str() method, used to convert variables to strings.

5. Running a Python file from the IDLE

Learn how to run a Python file from within IDLE. This is useful in order to be able to write larger programs and run them, as opposed to programming everything through the interactive console.

6. Getting user input in Python

Learn about the input() method, used to prompt the user for a string value.

7. The int() method to convert to Integers

Learn about the int() method, used to convert variables to an integer data type. Remember the variable value has have a format that you can convert to a number. This means converting something like "a" to an integer won't work.

8. The format() method to simplify String formatting

Learn about the format() method, probably one of the most used methods in Python. It's used to replace elements of a string with other elements, which let you format strings easily and concisely.


3. Magic Numbers in Python

1. Lists in Python

Lists are used to store groups of items in order. Learn about lists in Python in this video.

2. The for loop in Python

The for loop is one of two loops available to Python programmers.

3. Boolean expressions, True and False

Boolean expressions are True/False expressions. They are used to make decisions.

4. If statements in Python

Learn about the if statement, a construct which uses Boolean expressions to alter the flow of your programs.

5. The 'in' keyword to check whether a list contains an element

Learn about the "in" keyword in Python, essential to check whether an element is inside a list.

6. Giving the user multiple chances in our program

Let's change our application to allow our user to have multiple attempts at getting the right magic number.

7. Generating random integers in Python

Learn about the "random" module, and how we can use it to generate random integers in Python.

8. Defining our own methods in Python

Learn in this video how to define your own methods. This is essential to divide your programs into manageable chunks. This improves readability and reusability of your code.

9. Returning values from our methods in Python

Learn in this video how to return a value from a method. This is necessary so we can distribute the work that our program does across multiple methods.


4. A Lottery app

1. The String split() method

Learn about the string split() method, used to separate a string into a list, where each element is a part of the string.

2. List comprehension in Python

A key part of Python (and a fun part!) is list comprehension, which allows us to construct lists in place, using specific syntax.

3. Python Sets - what is a Set?

Learn about Sets in this video. Sets are not unique to Python, but they are extremely useful when dealing with unordered and unique groups of elements.

4. Set comprehension in Python

Learn about set comprehension, which is extremely similar to list comprehension.

5. Creating our lottery numbers

In this video we create the lottery numbers for our app.

6. Calculating the lottery winnings

In this video we calculate the winnings of the user by calculating a Set intersection.


5. More complex applications: a student registration system

1. Installing PyCharm, a professional Python tool

In this video we look at downloading PyCharm, arguably the most used Python IDE in the industry.

2. Setting up PyCharm on Mac

In this video we look at setting up PyCharm on Mac.

3. Setting up PyCharm on Windows

In this video we look at setting up PyCharm on Windows.

4. Dictionaries in Python

Learn about dictionaries in Python. These are essential data structure in the form of key-value pairs.

5. Advanced Dictionary usage in Python

Learn advanced dictionary usage in Python, such as including lists and other dictionaries inside a dictionary.

6. Methods returning dictionaries

Learn how a method returning a dictionary affects the dictionary.

7. Appending to a list in Python

Learn how to append (add at the end) and element to an existing list.

8. Adding marks to our student data structure

In this video we add marks to our student data structure by appending to the marks list.

9. The sum() method in Python

Learn about the sum() method, used to easily add all elements of a list. Here we use it to help calculate the average mark of a student.

10. Iterating over a dictionary's keys and values

Learn how to iterate over a dictionary. Here we need two iteration values, one for the key, and one for the value.

11. Creating the application menu

In the final video of this section, learn about creating a menu for our application so users can interact with it.


6. Object-Oriented Programming: a movie rental system

1. What are classes? Classes in Python

Learn about classes by comparing a Class to what we created in the last section. Learn how to implement classes in Python.

2. The Movie Class

Create the Movie class for this section's application.

3. The User Class (and the __repr__ method)

Learn about the __repr__ method, used when printing out an object, and create the User class.

4. The filter() method in Python

Learn about the filter() method, which is extremely useful. It is used to remove elements from a list matching a boolean expression.

5. More Movie operations and methods

Implement more methods of the Movie class with the help provided in this video.

6. Writing to a file in Python

Learn about opening files for reading and writing in Python.

7. Saving CSV files with our data

Learn about CSV (Comma-Separated Value) files and how to save our data to a file in this format.

8. Loading our data from CSV files

Learn about loading data from CSV files in this video.

9. Saving JSON files with our data

Learn about JSON (JavaScript Object Notation), and how to save our data to a file with this format. JSON is more advanced and nowadays more common than CSV, although CSV is still used in many places.

10. Loading our data from JSON files

Learn about loading data into our application by reading JSON files.

11. Argument unpacking in Python (the two asterisks)

Learn about an extremely common Python construct which is the double asterisk. It is called argument unpacking.

12. Creating the menu for our application

Create a menu for users to interact with our application in this video.


7. Introduction to PostgreSQL

1. Introduction to databases

In this video learn a bit more about what a database is, about relational database management systems, and also about other systems. We also touch into what scalability is and why it is important.

2. Installing PostgreSQL on Windows

In this video learn how to install PostgreSQL on Windows.

3. Using PostgreSQL on Windows

In this video learn how to use and run PostgreSQL on Windows.

4. Executing SQL queries on Windows

In this video learn how to execute SQL queries on your database on Windows.

5. Installing PostgreSQL on Mac

In this video learn how to install PostgreSQL on Mac.

6. Using PostgreSQL on Mac

In this video learn how to use and run PostgreSQL on Mac.

7. Executing SQL commands on Mac

In this video learn how to execute SQL queries on your database on Mac.

8. Using the sample data provided

In this video learn how to import the data provided in the downloadable resources.

9. SQL: The SELECT command

This video explains the SELECT command, and how you can construct queries using it.

10. SQL: filtering with WHERE

This video explains the WHERE command, and how you can filter queries with it.

11. SQL: LIMIT for limiting the number of results

This video explains the LIMIT command, and how you can limit the number of results returned by a query.

12. SQL: UPDATE data in a table

This video explains the UPDATE command, and how you can construct queries using it.

13. SQL: DELETE data from a table

This video explains the DELETE command, and how you can remove data from a table with it. Remember to use a WHERE clause too so you don't delete all your data!

14. SQL Wildcards for filtering unknowns

This video explains the different SQL wildcards you can use for fuzzy matching of data in your filters.

15. What is a JOIN?

This important lecture explains what a JOIN is, and why it is essential for relational databases to support this.

16. SQL: JOINs and JOIN examples

This video gives some examples of constructing JOINs.

17. SQL: GROUP BY for aggregation of data

This video explains the GROUP BY command, and how you can aggregate results with it.

18. SQL: ORDER BY for sorting data

This video explains the ORDER BY command, and how you can sort results with it.

19. SQL: CREATE TABLE

This video explains the CREATE TABLE command, and how you can create tables. It also talks about PRIMARY KEY, NOT NULL, CONSTRAINTS, and FOREIGN KEY.

20. SQL: INSERT INTO for adding data to a table

This video explains the INSERT INTO command, and how you can add data to a table using it.

21. SQL: SEQUENCE for auto-incrementing fields

This video talks about SEQUENCE, a PostgreSQL-only construct used to generate auto-incrementing values.

22. SQL: CREATE INDEX and advanced information about indexes

This video talks about what indexes are, how to create them (using CREATE INDEX), and also important things to remember about how PostgreSQL works with indexes, and multi-column indexes.

23. SQL: DROP TABLE for deleting tables and data

This video explains the DROP TABLE command, and how you can delete tables and their data.


8. Advanced PostgreSQL

1. SQL: VIEWs and what they are used for

Learn about VIEWs in SQL and what they are used for. VIEWs provide more flexibility and restrictions in some scenarios for data entry.

2. SQL: built-in functions and the HAVING construct

Learn about some of the SQL built-in functions and the HAVING construct.

3. Dates in SQL: an old problem

Learn about the age-old problem of dates in databases: timezones, representation, and daylight saving.

4. Other data types in SQL (including JSON in PostgreSQL)

Learn about more available data types in PostgreSQL, such as BYTEA and JSON.

5. Nested SELECT statements for complex queries

Learn about nested SELECT statements, which allow for much more flexible and complex queries.

6. The PostgreSQL SERIAL type

After looking at SEQUENCE, learn about the SERIAL type, which is a shorthand.


9. Python and PostgreSQL

1. Installing psycopg2 on Windows (2018 update)

This video, updated for 2018 updates of Windows and psycopg2, talks about how to install psycopg2 very easily on Windows.

2. Installing psycopg2 on Windows (older versions)

In this video we learn how to install Psycopg2 on Windows. It is a bit of a confusing process, so please bear with me!

3. Installing psycopg2 on Mac

In this video we learn how to set up psycopg2 on Mac. Fortunately, setting up on Mac or Linux is substantially simpler than on Windows.

4. Verifying everything works-don't proceed if it doesn't!

In this video we verify that the psycopg2 installation was successful. Make sure that it is, and if not, ask a question in the course Q&A and we'll help you out!

5. Mac OS X: Fixing psycopg2 'library not loaded' error

In this video we go through how to fix a problem with the PostgreSQL installation on Mac OS X 10.11. This problem is due to the way it installs alongside OS X 10.11 new feature SIP (System Integrity Protection).

6. What is a virtual environment?

In this video we look at an important part of the Python ecosystem: virtual environments (usually called virtualenvs).

7. psycopg2 on a virtualenv on Windows (2018 update)

In this video we cover how to very easily install psycopg2 on a virtual environment on Windows, using PyCharm.

8. Psycopg2 on a virtualenv on Windows (older versions)

In this video we install psycopg2 on a virtualenv on Windows so that our project can use it. It's essentially the same as installing on Windows, but we need to make sure that we are using the virtualenv's Python binary instead of the system Python.

9. Setting up the app structure, pip, and requirements.txt

In this video we set up the application structure, and we look at what pip is and how to create a requirements.txt file.

10. Recap on classes and object-oriented programming

In this video we review classes and how to create them, as they will be the foundation of this section's small app.

11. Saving to database from Python

In this video we look at saving our User object to the database using an INSERT statement executed with Python and psycopg2.

12. Loading from the database from Python

In this video we look at loading from the database using a SELECT statement executed with Python and psycopg2.

13. Removing some duplicate code from our app

In this video we remove a bit of duplicated code from our app and look into why readable and maintainable code is important.

14. Connection pooling and why it is important

In this video we look at connection pooling. Connection pooling is an extremely important part of an app when dealing with a relational database management system such as PostgreSQL, because it improves performance.

15. Creating the ConnectionPool class

In this video we create a ConnectionPool class which allows us to use the with...as... clause in Python.

16. Creating the ConnectionFromPool class

The ConnectionPool class was not exactly what we were looking for, so In this video we change it to a ConnectionFromPool class which does what we need.

17. Obtaining a cursor from the ConnectionFromPool class

In this video we look at obtaining a cursor from our ConnectionFromPool class as opposed to just a connection to PostgreSQL.

18. The Database class and selective initialisation

In this video we look at selectively initialising the connection pool by putting it in a Database class, as opposed to as a lone variable at the top of the file.

19. Cleaning up the Database class

In this video we clean up the Database class and review the meaning of the double asterisk sign-argument unpacking.

20. End of section review

In this video, we review what we have accomplished and learned! This section was an intense Python and psycopg2 learning experience, and we are now ready to learn more and build apps that use a great database system like PostgreSQL.


10. Python Web and APIs

1. What is an API?

An extremely important concept nowadays is the concept of API. Learn in this video what an API is, about different types of APIs, including REST APIs!

2. Making requests in Python

Learn how to make arbitrary web requests in Python. This is useful to request websites and web APIs.

3. What is OAuth?

Learn about what OAuth is in this video. This is extremely useful for those "log in with..." buttons.

4. Creating a Twitter app

In this video we quickly create the Twitter app so we can get our consumer key and secret, which are used to identify and sign our Twitter app.

5. Setting up Twitter login

In this video we set up necessary constants for our Twitter login.

6. Getting the OAuth request token

Learn in this video about the request token, and how to retrieve one using Twitter and the oauth2 Python library.

7. More on the Python debugger-an essential tool

Important video-learn about the Python debugger and interacting with it through PyCharm. The debugger is an essential tool for any programmer, and we will be using it often!

8. Getting authorization by the user

In this video we get the authorization code from the user, which we need in order to get an access token.

9. Getting the OAuth access token

In this video learn about using the request token and the authorization code provided by the user to get the access token, which is used to represent the user in Twitter and our Twitter app.

10. Performing Twitter requests: getting images

In this video we learn about using the Twitter Search API to search through recent tweets.

11. Reusing code from the last section to save users

In this video we reuse code from the last section and re-implement the User class and saving to database. Now that we have that, it's easy to save access tokens alongside our user details.

12. Creating users in our app

In this video we create our User object with an access token.

13. Retrieving users in our app

In this video we learn about retrieving users from the database together with their Twitter access tokens so we can then make requests on their behalf.

14. Cleaning up the code-extremely important!

This very important lecture covers cleaning up the code and making it maintainable and readable. This is essential!

15. Introduction to Flask and Python Web Development

Flask is a Python library which allows us to create web interfaces. In this video we create a simple Flask application to serve HTML content over the internet.

16. Adding a Twitter login endpoint

In this video we continue with our Flask application and add an endpoint to send users to Twitter to authorize our app.

17. Adding Twitter authorization

We add Twitter authorization to our app by having Twitter redirect to our app's URL.

18. Creating the user profile

In this video we create the user profile, which is just another endpoint in our app.

19. The Flask before_request decorator

In this video we look at a very useful decorator in Flask, the before_request decorator.

20. Checking if a user is already logged in

In this video we learn to check if a user is already logged in, so we avoid re-authorizing.

21. Searching tweets and displaying them

In this video we create another endpoint that interacts with the Twitter API to search for tweets and display them in a HTML page.

22. Searching for different things

In this video we make sure that the search endpoint is not limited to searching only with one query, but rather that the query is dynamic.

23. What is Bootstrap?

In this video we look at Bootstrap, which is a framework for rapid styling of web pages.

24. Writing our own CSS

In this video we quickly look into how we might go about writing our own CSS.

25. Allowing users to perform custom searches

In this video we create a form to allow our users to perform custom searches using the Twitter API.

26. Adding sentiment analysis with another API

In this video we add sentiment analysis to our web application by interacting with yet another API. This is why learning to make API requests is important!


11. Introduction to Git and GitHub

1. What is Git?

Learn about what Git is and why you should care about it. Remember to put your projects on Git for others and companies to see!

2. Installing Git on Mac and Windows

Learn how to install Git on Mac and Windows. In Windows, this includes a UNIX terminal emulator which is essential.

3. Introduction to the UNIX terminal

Learn about some commands you can use in the UNIX terminal to move around, create directories, and more.

4. The VIM text editor, a powerful terminal editor

Learn about VIM, arguably the most popular terminal text editor in the world.

5. Dealing with files in the UNIX terminal

Learn how to move, rename, and display text contents of files.

6. What is a Git repository?

A lecture video explaining what a Git repository is, and the different layers of functionality it provides.

7. git init - create a Git repository

MongoDB Queries: $in and $nin

8. git add and git commit - staging and committing

Learn about the git init command, used to create a local Git repository.

9. git log - viewing past commits

Learn about git add and git commit, used to add files to the staging area and to commit them, creating a snapshot of the differences between previous snapshots and the newly added files.

10. Creating a repository on GitHub

Learn how to display previous commits using the simple git log command.

11. git remote - managing remote repositories

Learn about git remote, a command used to manage remote repositories. More specifically we will look at git remote add, and how to use it.

12. Adding your SSH key to GitHub

Learn about SSH keys, what they are useful for, and how to generate one and add it to your GitHub account.

13. What is a README file? Introduction to Markdown

Learn about README files and how to write them using the popular syntax Markdown.

14. git pull - pulling other's changes

Learn about git pull, used to download changes made by other people in the remote repository.


12. Advanced Python

1. OOP: Inheritance

In this video we learn about inheritance in Python. Object-Oriented Programming uses inheritance to simplify code, reduce duplications, and make it make sense for programmers.

2. OOP: Multiple Inheritance in Python

In this video we look at multiple inheritance in Python. It may not be something you'll be using every day, but it nevertheless extends the capabilities of Python and is important to know about.

3. OOP: What is composition?

Learn about composition, which is a way of structuring your object-oriented programming style applications.

4. OOP: What is encapsulation?

Learn about encapsulation In this video, which is another object-oriented programming principle.

5. Introduction to Exceptions in Python

Exceptions are very widely used in Python. Exceptions are meant to occur when an error happens in your program. Fortunately, using Exceptions, we can recover from any expected errors!

6. Creating our own Exceptions

Sometimes the built-in Exceptions don't give the programmer enough granularity in detail when debugging errors. We can create our own Exceptions to give us some more information!

7. Some of the available built-in Exceptions

Python has many built-in Exceptions for all range of errors. Learn about a few of them In this video.

8. Python built-in methods

Python classes also have a number of built-in methods to do standard things, such as multiplication or comparison. Learn about them In this video.

9. Assertions in Python

An assertion is a short line of code used to verify something. It's more than just an if-statement though! Learn about assertions In this video.

10. Lambda expressions in Python

Learn about lambda expressions in Python in this video. Lambda expressions are very useful small-and sometimes anonymous-functions.

11. More uses of lambda expressions

Lambda expressions are important, so let's look at a few more examples of them in this video.

12. Lambda expressions in the wild

In order to further cement your learning, I give you an example of lambda expressions as I've used them myself in professional projects.

13. Introduction to unit testing with unittest

Unit testing (and other types of testing) are extremely important as they make your development efforts swift and give you some confidence that what you are writing is what you want to be writing. Learn about Python's unittest library and about unit testing In this video.


13. Data Structures and Algorithms

1. What are data structures?

In this video video, learn what data structures are and what they are useful for. Not only are they essential parts of computer science, but you'll also get asked about data structure very often in job interviews.

2. What is a Linked List?

In this video video, learn what a linked list is. It's the data structure on which we are going to be basing other data structures.

3. Introduction to Linked List Assignment

In this video we look at the next assignment, which involves implementing our own Linked List data structure.

4. Programming our own Linked List in Python

In this video look at solving the assignment and implementing the methods of our own Linked List in Python. Make sure to attempt it on your own first!

5. Creating a Queue

In this video we look at what a Queue is.

6. Introduction to Queue Assignment

In this video we look at the next assignment, which will involve implementing some new Linked List and Queue methods.

7. Programming our own Queue in Python

In this video we look at implementing the assignment specification. Make sure to attempt on your own first!

8. Creating a Stack

In this video we look at what a Stack is, which is another data structure based on the Linked List.

9. Introduction to Stack Assignment

In this video we implement the Stack assignment. Make sure to attempt it on your own first!

10. Programming our own Stack in Python

In this video we implement the Stack assignment.

11. Creating a Binary Tree

In this video we look at what a Binary Tree is. It's a data structure not based on the Linked List.

12. Introduction to Binary Tree Assignment

In this video we introduce the Binary Tree assignment, which will include implementing some methods of a binary tree.

13. Programming our own Binary Tree in Python

In this video we implement the Binary Tree assignment. Make sure to attempt it on your own first!

Course Content

  1. The Complete Python and PostgreSQL Developer Course

About The Provider

Packt
Packt
Birmingham
Founded in 2004 in Birmingham, UK, Packt’s mission is to help the world put software to work in new ways, through the delivery of effective learning and i...
Read more about Packt

Tags

Reviews