Monday's class: -> Review (mostly): start at 2:30 Exam logistics: -> Next thursday: same time as your exam 1 -> All SQL Homework logistics: -> Personal databases Lecture 16 Exercise logistics: -> Ready one hour after lecture ------------------ Views: -------- CREATE VIEW langcounts(movieid, numlanguages) AS SELECT movieid , count(*) FROM movieslanguages GROUP BY movieid; SELECT m.title , numl.numlanguages FROM movies m , langcounts numl WHERE m.movieid = numl.movieid and numl.numlanguages = (SELECT max(numlanguages) FROM langcounts) ORDER BY title ASC ; Access Control: ---------------- create user with encrypted password inherit login createdb; create role dbstudent ; -- implicit: login inherit create role dbta ; grant dbstudent to sibel ; grant dbstudent to sibel_student ; CREATE ROLE joe LOGIN INHERIT;