Working with Relational Databases - What Are Some Common Relational Databases, and How Do You Install and Use Postgres?

Tell us what’s happening:

I have wsl ubuntu distro installed. Followed the Linux installation, but the page doesn’t have next steps to install the components. psql is not already installed. Any advice appreciated!

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36

Challenge Information:

Working with Relational Databases - What Are Some Common Relational Databases, and How Do You Install and Use Postgres?

follow the instructions on the postgres site

I’ve already installed it. The page has no instructions after the installation command:

sudo apt install postgresql-18

on the components listed on the windows instructions page on freecodecamp:

"Then, select the component that you want to install. There are four possible components:

  • PostgreSQL Server, the database engine itself.
  • pgAdmin 4, a user-friendly tool for database management.
  • Stack Builder, a tool for downloading and installing additional PostgreSQL-related software and extensions
  • And Command Line Tools, to interact with the PostgreSQL server directly from your terminal. This includes psql, an interactive terminal for executing SQL queries.

When you’re ready, click Next.

Then, select a directory to store your data. You will see a default path but you can customize this. When you’re ready, click Next.

Now you’ll need to enter a password for the database superuser, the user with unrestricted access to all databases and objects. Type in your password, retype it, and then click Next.

Then, select the port number the server should listen on. By default, it’s 5432. Then, click Next.

You’ll need to choose a locale for the new database cluster. This is important for the database to interpret locale-sensitive data types. Then, click Next.

Finally, you’ll see a pre-installation summary. Take a moment to review this and click Next.

You will need to confirm that you want to start the installation process. If you click Next, the process will start. It should only take a few minutes.

When the process is completed, based on the components that you installed, you may have to choose if you want to launch Stack Builder to download and install additional tools, drivers, and applications.

If you decide to launch Stack Builder, you’ll see a screen where you can start the installation. Alternatively, you can click Cancel to do this later on."

installing things on linux and on windows is different but you are installing the packages all the same

Yes so how do I install the components for wsl/linux since the postgres does not have further instructions regarding how to install the components

I’m at https://www.freecodecamp.org/learn/full-stack-developer/workshop-database-of-video-game-characters/build-a-database-of-video-game-characters and psql is not installed. There are no specific instructions on installing psql from the postgresql page for linux

did you run the installation command? was it succesfful? then it’s installed

if the other packages are not installed, install those too, use the same command but with their name

you can check if psql is installed with psql --version