DROP TABLE if exists Person;

CREATE TABLE Person (
	personid	INT  UNSIGNED  NOT NULL  AUTO_INCREMENT  PRIMARY KEY, 
	name		CHAR(30),
	email		CHAR(30),
	password	CHAR(30));
	
DROP TABLE if exists Schedule;

CREATE TABLE Schedule (
	scheduleid	INT  UNSIGNED  NOT NULL  AUTO_INCREMENT  PRIMARY KEY,
	description	CHAR(30),
	personid	INT  UNSIGNED);

DROP TABLE if exists Timeframe;

CREATE TABLE Timeframe (
	timeframeid	INT  UNSIGNED  NOT NULL  AUTO_INCREMENT  PRIMARY KEY,
	day			CHAR(2),
	starttime	CHAR(11),
	endtime		CHAR(11),
	scheduleid	INT  UNSIGNED);
	
INSERT INTO Person (name, email, password)
VALUES ('blah1','blah2','blah3');

INSERT INTO Schedule (description, personid)
VALUES ('blah4',1);

INSERT INTO Timeframe (day,starttime, endtime, scheduleid)
VALUES ('b5','01:00','02:00',1);
	
	