CREATE DATABASE escola;
CREATE TABLE turma(
id INT SERIAL PRIMARY KEY,
nome_turma VARCHAR(100) NOT NULL
);
CREATE TABLE aluno(
id INT SERIAL PRIMARY KEY,
nome VARCHAR(100) NOT NULL,
nota NUMERIC (100) DEFAULT 0,
FOREIGN KEY (id_turma) REFERENCES turma(id)
);
SELECT nome, nota
FROM aluno
WHERE nota >=60
ORDER BY nota ASC
To embed this project on your website, copy the following code and paste it into your website's HTML: