CS201 MID TERM SOLVED MCQs || PAST PAPERS || GROUP-1 || INTRODUCTION TO PROGRAMMING || VuTech Visit Website For More Solutions www.vutechofficial.blogspot.com …
CS101 ASSIGNMENT NO. 2 FALL 2022 || 100% RIGHT SOLUTION || INTRODUCTION TO COMPUTING || BY VuTech
Visit Website For More Solutions
www.vutechofficial.blogspot.com
SEND WHATSAPP OR E-MAIL FOR ANY QUERY
0325-6644800
kamranhameedvu@gmail.com
Questions No 0110 marks
A software developer has built a relational database
model for the Learning Management Systemofanonlinelearningwebsite.Variousrelations(tables)aredefinedtostoredatarecordsrelatedtoeachentityinaseparaterelation.ThreeoftheRelations(STUDENT,COURSE,andENROLLMENT)definedinthatdatabasemodelalongwiththeirattributesaregivenbelow:
STUDENT
StudentID
StudentName
DegreeProgram
ResidentCity
…
…
…
…
…
…
…
…
…
…
…
…
COURSE
CourseCode
CourseTitle
TeacherID
DegreeProgram
CreditHours
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
ENROLLMENT
StudentID
CourseID
Semester
…
…
…
…
…
…
…
…
…
The developer needs to extract the following information
given in Table-1 from his defineddatabasemodelusingtherelationaldatabasequeriesthatconsistofSELECT,PROJECTandJOINoperators.
Now,inthebelowgiventable(Table-2),somerelationaldatabaseoperations(Queries) relatedtotheabovedatabasemodelaredefinedalongwiththename ofresultingnewrelation.Thenameofthe
resulting new relation is also used as reference to identify that query (i.e.
each query isreferencedas A,B,
C, D,E,F, G, H,I, J, K, andL).
Table-2:RelationalQueries
RelationalQuery(Operation)
Name of theResulting Relation(also a ReferenceLabel)
J <- SELECT Columns[StudentName, DegreeProgram] from
STUDENT
J
K<-SELECT[DegreeProgram ='BSCS']fromSTUDENT
K
L<-SELECTfromCOURSEwhereCreditHours>=3
L
This table (Table-2)
contains both syntactically correct and incorrect relational database queries(referenced
as A to N). Out of these twelve (12) queries, six (6) syntactically correct
queries canbeused to extract theinformation required inthetable-1.
You
are required to identify the correct relational database query from Table-2: RelationalQueriesforeachofthe“RequiredInformation”entryinTable-1andmentionitsreferencelabelin
the 2nd column of the below given table against the Sr. no. of Required
Information. Forexample, the answer to “Sr. no. 1” entry
of “Required Information” column is query “A”whichis solved in the belowgiven
table.
Now, you need to fill the remaining five (5) entries in
the below given table with the Referencelabelofcorrectrelationaldatabase againsteachSr. No.ofthe requiredinformationtable.
(ProvideyourAnsweronlyin
thebelow given Table)
Sr. No. of Required
Information given inTable-1
ReferencelabeloftheCorrectRelationalQuery
{OutofA, B,C, D, E,F, G, H, I,J, K, L}
fromTable-2
1
A
(solved)
2
K
3
I
4
E
5
L
6
G
Note: You don’t need to copy the assignment statement or
write any queries in your solution file.Justmentionthe“referencelabel”ofthecorrectrelationaldatabasequeryfromtable-2againsttheSr.No.
of“RequiredInformation”intheabovetable.
BestofLuck
Visit Website For More Solutions
www.vutechofficial.blogspot.com
KINDLY, DON’T COPY PASTE
SUBSCRIBE, SHARE, LIKE AND COMMENTS FOR MORE UPDATES
We provide Virtual University of Pakistan Study Materials such as Solution of Assignments, GDBs, Mid Term Solved Papers, Final Term Solved Papers, Mid Term Solved MCQs, and Final Term Solved MCQs. We also provide regular Semester Quizzes, Updated Handouts, and Short Questions and Answers. We help you with your research and many other educational-related topics, as far as we know. Furthermore, Share your problem with us and Please feel free to ask any related questions.