text: DROP DATABASE IF EXISTS employees; 
  CREATE DATABASE employees;
  USE employees;
  
  CREATE TABLE departments(id INT AUTO_INCREMENT NOT NULL,
  name VARCHAR(30) NOT NULL,
  PRIMARY KEY(id));
  
  CREATE TABLE roles (id INT AUTO_INCREMENT NOT NULL,
  title VARCHAR(30) NOT NULL,
  salary DECIMAL,
  department_id INT NOT NULL,
  PRIMARY KEY(id),
  FOREIGN KEY(department_id) REFERENCES departments(id) ON DELETE CASCADE);
  
  CREATE TABLE employee(id INT AUTO_INCREMENT NOT NULL,
  first_name VARCHAR(30) NOT NULL,
  last_name VARCHAR(30) NOT NULL,
  role_id INT NOT NULL,
  manager_id INT DEFAULT NULL,
  PRIMARY KEY(id),
  FOREIGN KEY(role_id) REFERENCES roles(id)ON DELETE CASCADE ,
  FOREIGN KEY (manager_id) REFERENCES employee(id) ON DELETE SET NULL
  );
  
  