Celestial Bodies Database - Build a Celestial Bodies Database

Tell us what’s happening:
Describe your issue in detail here.
TERMINAL FOR THE CELESTIAL PROJECT
Error : syntax error near unexpected token `(', How to comply with the Instructions & Get a Pass from the systwm

Your code so far

codeally@89460b308f8b:~/project$ \d galaxy
bash: d: command not found
codeally@89460b308f8b:~/project$ psql --username=freecodecamp --dbname=postgres
Border style is 2.
Pager usage is off.
psql (12.9 (Ubuntu 12.9-2.pgdg20.04+1))
Type "help" for help.

postgres=> \d galaxy
Did not find any relation named "galaxy".
postgres=> CREATE TABLE galaxy (galaxy_id SERIAL PRIMARY KEY NOT NULL, speed INT, description TEXT);
CREATE TABLE
postgres=> \d galaxy
                                   Table "public.galaxy"
+-------------+---------+-----------+----------+-------------------------------------------+
|   Column    |  Type   | Collation | Nullable |                  Default                  |
+-------------+---------+-----------+----------+-------------------------------------------+
| galaxy_id   | integer |           | not null | nextval('galaxy_galaxy_id_seq'::regclass) |
| speed       | integer |           |          |                                           |
| description | text    |           |          |                                           |
+-------------+---------+-----------+----------+-------------------------------------------+
Indexes:
    "galaxy_pkey" PRIMARY KEY, btree (galaxy_id)

postgres=> CREATE TABLE star(star_id PRIMARY SERIAL KEY NOT NULL, radius INT NOT NULL, Color VARCHAR(255) NOT NULL, CONSTRAINT fk_galaxy FOREIGN KEY(galaxy_id) REFERNCES galaxy(galaxy_id));
ERROR:  syntax error at or near "PRIMARY"
LINE 1: CREATE TABLE star(star_id PRIMARY SERIAL KEY NOT NULL, radiu...
                                  ^
postgres=> CREATE TAVLE star(star_id SERIAL PRIMARY KEY NOT NULL, radius INT NOT NULL, color VARCHAR(255) NOT NULL, Name  VARCHAR(255), Not Null, CONSTAINT fk_galaxy FOREGIN KEY(galaxy_id) REFERNCES galaxy(galaxy_id));
ERROR:  syntax error at or near "TAVLE"
LINE 1: CREATE TAVLE star(star_id SERIAL PRIMARY KEY NOT NULL, radiu...
               ^
postgres=> CREATE TAVLE star(star_id SERIAL PRIMARY KEY NOT NULL, radius INT NOT NULL, color VARCHAR(255) NOT NULL, Name  VARCHAR(255), Not Null, CONSTAINT^Z[1]+  Stopped                 psql --username=freecodecamp --dbname=postgres
codeally@89460b308f8b:~/project$ CREATE TABLE star(star_id SERIAL PRIMARY KEY NOT NULL, radius INT NOT NULL, color VARCHAR(255) NOT NULL, Name  VARCHAR(255), Not Null, CONSTAINT fk_galaxy FOREGIN KEY(galaxy_id) REFERNCES galaxy(galaxy_id));
bash: syntax error near unexpected token `('
codeally@89460b308f8b:~/project$ /d galaxy
bash: /d: No such file or directory
codeally@89460b308f8b:~/project$ /d 
bash: /d: No such file or directory
codeally@89460b308f8b:~/project$ \d galaxybash: d: command not found
codeally@89460b308f8b:~/project$ \d
bash: d: command not found
codeally@89460b308f8b:~/project$ CREATE TABLE star(star_id SERIAL PRIMARY KEY NOT NULL, color VARCHAR(255) NOT NULL,  name  VARCHAR(255) NOT NULL, CONSTRAINT fk_galaxy FOREIGN KEY(galaxy_id) REFERNCES galaxy(galaxy_id)); 
bash: syntax error near unexpected token `('
codeally@89460b308f8b:~/project$ 

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/111.0

Challenge: Celestial Bodies Database - Build a Celestial Bodies Database

Link to the challenge:

You need to add the code to the psql prompt not the bash prompt

Thank u Very much , I Req the moderator to mark this thread as Closed…

Also, you have typos here and several other places too.