15 lines
809 B
SQL
15 lines
809 B
SQL
CREATE TABLE IF NOT EXISTS programs (
|
|
id INT AUTO_INCREMENT PRIMARY KEY,
|
|
institution_id INT,
|
|
name VARCHAR(255) NOT NULL,
|
|
description TEXT,
|
|
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
|
|
updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
|
FOREIGN KEY (institution_id) REFERENCES institutions(id) ON DELETE CASCADE
|
|
);
|
|
|
|
INSERT INTO programs (institution_id, name, description) VALUES
|
|
(1, 'Bachelor of Computer Science', 'A comprehensive program covering all aspects of computer science.'),
|
|
(1, 'Master of Artificial Intelligence', 'Advanced studies in AI, machine learning, and robotics.'),
|
|
(2, 'Bachelor of Fine Arts', 'Explore your creativity in our renowned BFA program.'),
|
|
(3, 'Master of Business Administration', 'An MBA for the modern business world.'); |