CREATE TABLE alumno(
    idAlumno tinyint unsigned NOT NULL,
    correo varchar(255) NOT NULL,
    contrasenia varchar(100) NOT NULL,
    nombre varchar (80) NOT NULL,
    web varchar (50),
    CONSTRAINT pk_alumno PRIMARY KEY (idAlumno)
    CONSTRAINT correo_unico UNIQUE(correo),
    CONSTRAINT WEB_unicA UNIQUE(web)
);
CREATE TABLE valoracion(
    idRec smallint unsigned AUTO_INCREMENT,
    categoria char(11) NOT NULL,
    momento varchar(100) NOT NULL,
    descrip varchar(255) NOT NULL,
    Alurec tinyint unsigned NOT NULL,
    Aluenv tinyint unsigned NOT NULL,
    CONSTRAINT pk_valoracion PRIMARY KEY (idRec),
    CONSTRAINT fk_receptor FOREIGN KEY (Alurec) REFERENCES alumno(idAlumno),
    CONSTRAINT fk_emisor FOREIGN KEY (Aluenv) REFERENCES alumno(idAlumno)
);

CREATE INDEX ix_alumno_nombre ON alumno(nombre);

INSERT INTO alumno () VALUES (1, 'Carlos', 'Carlos@fundaloyola.com', 'Carlos1', 'webCarlos');
INSERT INTO alumno () VALUES (2, 'David', 'David@fundaloyola.com', 'David2', 'webDavid');
INSERT INTO alumno () VALUES (3, 'Celia', 'Celia@fundaloyola.com', 'Celia3', 'webCelia');
INSERT INTO alumno () VALUES (4, 'Maria', 'Maria@fundaloyola.com', 'Maria4', 'webMaria');
INSERT INTO alumno () VALUES (5, 'Fernando', 'Fernando@fundaloyola.com', 'Fernando5', 'webFernando');
INSERT INTO alumno () VALUES (6, 'Alvaro', 'Alvaro@fundaloyola.com', 'Alvaro6', 'webAlvaro');
INSERT INTO alumno () VALUES (7, 'Jose Luis', 'JoseLuis@fundaloyola.com', 'Jose7', 'webJose');
INSERT INTO alumno () VALUES (8, 'Javier Arias', 'JavierA@fundaloyola.com', 'JavierA8', 'webJavierA');
INSERT INTO alumno () VALUES (9, 'Juan Carlos', 'JuanCarlos@fundaloyola.com', 'Juan9', 'webJuan');
INSERT INTO alumno () VALUES (10, 'Adrian', 'Adrian@fundaloyola.com', 'Adrian10', 'webAdrian');
INSERT INTO alumno () VALUES (11, 'Levi', 'Levi@fundaloyola.com', 'Levi11', 'webLevi');
INSERT INTO alumno () VALUES (12, 'Angel', 'Angel@fundaloyola.com', 'Angel12', 'webAngel');
INSERT INTO alumno () VALUES (13, 'Alberto', 'Alberto@fundaloyola.com', 'Alberto13', 'webAlberto');
INSERT INTO alumno () VALUES (14, 'Eduardo', 'Eduardo@fundaloyola.com', 'Eduardo14', 'webEduardo');
INSERT INTO alumno () VALUES (15, 'Alejandro', 'Alejandro@fundaloyola.com', 'Alejandro15', 'webAlejandro');
INSERT INTO alumno () VALUES (16, 'Zeus', 'Zeus@fundaloyola.com', 'Zeus16', 'webZeus');
INSERT INTO alumno () VALUES (17, 'Joaquin', 'Joaquin@fundaloyola.com', 'Joaquin17', 'webJoaquin');
INSERT INTO alumno () VALUES (18, 'Paloma', 'Paloma@fundaloyola.com', 'Paloma18', 'webPaloma');
INSERT INTO alumno () VALUES (19, 'Miguel', 'Miguel@fundaloyola.com', 'Miguel19', 'webMiguel');
INSERT INTO alumno () VALUES (20, 'Mauricio', 'Mauricio@fundaloyola.com', 'Mauricio20', 'webMauricio');
INSERT INTO alumno () VALUES (21, 'Pablo', 'Pablo@fundaloyola.com', 'Pablo21', 'webPablo');
INSERT INTO alumno () VALUES (22, 'Javier Sanchez', 'JavierS@fundaloyola.com', 'JavierS22', 'webJavierS');
INSERT INTO alumno () VALUES (23, 'Toni', 'Toni@fundaloyola.com', 'Toni23', 'webToni');
INSERT INTO alumno () VALUES (24, 'Rafa', 'Rafa@fundaloyola.com', 'Rafa24', 'webRafa');