Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I need help with number 3,4,7,8,10, and 11. If you don\'t know the language that

ID: 3737290 • Letter: I

Question

I need help with number 3,4,7,8,10, and 11.

If you don't know the language that is fine, I just need help with the written out logic of them.

Your assignment: Consider the JSON database in the file sampleUnivDB.jsonencodes in JSON the following tables: Department (dcode, dname, chair) Course (dcode, cno, title, units) Prereq (dcode, cno, pcode, pno) Class (class, dcode, cno, instr) Faculty (ssn, name, dcode, rank) Student (ssn, name, major, status) Enrollment (class, ssn) Transcript (ssn, dcode, cno, grade) Note that the The primary keys are underlined. The meaning of the primary key is that there cannot be two different tuples in the relation with identical values for the primary key. Some explanations of attributes (variable names) are as follows. Chair in Department refers to SSN in Faculty table. Instr refers to Ssn in Faculty table, and ssn in Transcript refers to Ssn in Student table. Class is a unique ID for each offering of a course. For example, a class with class 21may be an offering of CS 330, in which case, we may have a tuple like in the Class table. in Prereq table refers to in the Course table, i.e., they refer to courses. A example row in Prereq table is , which means that CS 450 needs CS 330 as a prerequisite course. Other foreign keys and meanings of the tables should be obvious Consider each of these table names (Department, Course, etc.) as predicates, with the interpretation that the predicate returns TRUE for a tuple if and only if this tuple is in the database table. For example, Enrollment(class, ssn) will now represent a predicate that evaluates to TRUE if the pair (class, ssn) is in the corresponding relation, and FALSE otherwise

Explanation / Answer

Here pre-requisite means, they have to complete some course for enrolling to a course. That is given in the pre-req table.

In Q 3. You ve to display the courses which is not present in the PREREQ TABLE.

In Q 4, You have to display the studentd's SSN whose dcode='CS' and cno=330 from the CLASS table and also has completed the course specified for the cno 330 in the PREREQ table

In Q 7, display SSN, Student Name from Student table where grade ='A'. // if grade specified in student table , then you can take from there or take the grade attribute from Result table

In Q. 8, display SSN, Student Name from Student table which do not have entry or value in the PREREQ table

In Q 10, display class, dcode,cno from class table where no. of students enrolled <=2.

In Q11, display class, dcode,cno from class table where no. of students enrolled =2.

These are only logic for the query. You have to translate this into the language specified.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote