{"Campuses": {"columns": [[0, "Id", "INTEGER", 0, null, 1], [1, "Campus", "TEXT", 0, null, 0], [2, "Location", "TEXT", 0, null, 0], [3, "County", "TEXT", 0, null, 0], [4, "Year", "INTEGER", 0, null, 0]], "primary_keys": ["Id"], "foreign_keys": [], "unique_constraints": [], "check_constraints": []}, "csu_fees": {"columns": [[0, "Campus", "INTEGER", 0, null, 1], [1, "Year", "INTEGER", 0, null, 0], [2, "CampusFee", "INTEGER", 0, null, 0]], "primary_keys": ["Campus"], "foreign_keys": [[0, 0, "Campuses", "Campus", "Id", "NO ACTION", "NO ACTION", "NONE"]], "unique_constraints": [], "check_constraints": []}, "degrees": {"columns": [[0, "Year", "INTEGER", 0, null, 1], [1, "Campus", "INTEGER", 0, null, 2], [2, "Degrees", "INTEGER", 0, null, 0]], "primary_keys": ["Year", "Campus"], "foreign_keys": [[0, 0, "Campuses", "Campus", "Id", "NO ACTION", "NO ACTION", "NONE"]], "unique_constraints": [[[0, 0, "Year"], [1, 1, "Campus"]]], "check_constraints": []}, "discipline_enrollments": {"columns": [[0, "Campus", "INTEGER", 0, null, 1], [1, "Discipline", "INTEGER", 0, null, 2], [2, "Year", "INTEGER", 0, null, 0], [3, "Undergraduate", "INTEGER", 0, null, 0], [4, "Graduate", "INTEGER", 0, null, 0]], "primary_keys": ["Campus", "Discipline"], "foreign_keys": [[0, 0, "Campuses", "Campus", "Id", "NO ACTION", "NO ACTION", "NONE"]], "unique_constraints": [[[0, 0, "Campus"], [1, 1, "Discipline"]]], "check_constraints": []}, "enrollments": {"columns": [[0, "Campus", "INTEGER", 0, null, 1], [1, "Year", "INTEGER", 0, null, 2], [2, "TotalEnrollment_AY", "INTEGER", 0, null, 0], [3, "FTE_AY", "INTEGER", 0, null, 0]], "primary_keys": ["Campus", "Year"], "foreign_keys": [[0, 0, "Campuses", "Campus", "Id", "NO ACTION", "NO ACTION", "NONE"]], "unique_constraints": [[[0, 0, "Campus"], [1, 1, "Year"]]], "check_constraints": []}, "faculty": {"columns": [[0, "Campus", "INTEGER", 0, null, 0], [1, "Year", "INTEGER", 0, null, 0], [2, "Faculty", "REAL", 0, null, 0]], "primary_keys": [], "foreign_keys": [[0, 0, "Campuses", "Campus", "Id", "NO ACTION", "NO ACTION", "NONE"]], "unique_constraints": [], "check_constraints": []}}
CREATE TABLE Campuses (
    Id INTEGER   PRIMARY KEY,
    Campus TEXT,
    Location TEXT,
    County TEXT,
    Year INTEGER
);

CREATE TABLE csu_fees (
    Campus INTEGER   PRIMARY KEY,
    Year INTEGER,
    CampusFee INTEGER,
    FOREIGN KEY (Campus) REFERENCES Campuses(Id)
);

CREATE TABLE degrees (
    Year INTEGER   PRIMARY KEY,
    Campus INTEGER   PRIMARY KEY,
    Degrees INTEGER,
    PRIMARY KEY (Year, Campus),
    UNIQUE (Year, Campus),
    FOREIGN KEY (Campus) REFERENCES Campuses(Id)
);

CREATE TABLE discipline_enrollments (
    Campus INTEGER   PRIMARY KEY,
    Discipline INTEGER   PRIMARY KEY,
    Year INTEGER,
    Undergraduate INTEGER,
    Graduate INTEGER,
    PRIMARY KEY (Campus, Discipline),
    UNIQUE (Campus, Discipline),
    FOREIGN KEY (Campus) REFERENCES Campuses(Id)
);

CREATE TABLE enrollments (
    Campus INTEGER   PRIMARY KEY,
    Year INTEGER   PRIMARY KEY,
    TotalEnrollment_AY INTEGER,
    FTE_AY INTEGER,
    PRIMARY KEY (Campus, Year),
    UNIQUE (Campus, Year),
    FOREIGN KEY (Campus) REFERENCES Campuses(Id)
);

CREATE TABLE faculty (
    Campus INTEGER,
    Year INTEGER,
    Faculty REAL,
    FOREIGN KEY (Campus) REFERENCES Campuses(Id)
);