/*
 * demo.ddl
 *
 * Database definitions for student-room assignment demonstration database.
 *
 */

// This record type will store information on available dorm rooms

#record room on "room.dat" using
  {
    string 15 dorm;
    int number;
  };

// This record type will store information on students

#record student on "student.dat" using
  {
    string 20 lastName;
    string 20 firstName;
    float gpa;
    date dateArrived;
  };

// This set type will store information about what students live in what room
// The room is made the set owner, because one room can have multiple students,
// but each student can live in (at most) one room.

#set occupiedBy owner room member student insertion manual retention optional;

// For completeness, we'll also use a keeplist, though it is not strictly
// needed for this problem!

#keeplist tempKeep;