1Get supplier names for suppliers who supply all parts except P1. 2Get supplier
ID: 3927611 • Letter: 1
Question
1Get supplier names for suppliers who supply all parts except P1.
2Get supplier names and the number of parts and total quantity supplied.
Suppliers S#| SNAME | STATUS | CITY S1 Smi th S2 Jones30 S3 Blake S4 Clark S5 Adams S6 Our melyour agelOttawa SE SNAME STATUS CITY 52-Jones [30Paris- 20 ondon 30 20 30 aris ondon Athens Parts PH PNAIME COLOR WEIGHT CITY P#PNAME COLOR WEIGHT CITY P1 Nut Red 12.0 London P2 Bolt Green 17.0 Paris P2 Bolt Green 17. 0 Paris P3 Screw Blue 17.0 Osl P4 Screw Red 14.0 London P5 Cam Blue 12. 0 Paris P6 Coged 19.0 London S#P#QTY S1 P1 300 s1 P2 200 s1 P3 400 S1 P4 200 S2 P1 300 $2 P2 400 $3 P2 200 S4 P2 200 54P41500! S4 P5 400Explanation / Answer
1)
Tuple relational calculus : T:< sid >|SSuppliersPparts CSP (P[sid] =S[sid]P[pid] =C[pid]T[sid] =S[sid] -|sid=p1)}
Domain relational calculus : (X:sid)|SNA Suppliers(X, SN, APP NL(Parts(P, P N, L)C SP(X, P, C) ^ SP[sid]/= 'p1';
2)Tuple relaional calculus : {T:< sname > ^ T:<Add(P)>^ T:<Add(QTY) T1Suppliers(XP arts(color] =redYCatalog(Y[pid] =X[pid]Y[sid] =T1[id]))T[sname] =T1[sname]}
Domain relational calculus: Y:sname^add(parts)^add(QTY)|XZ Suppliers(X, Y, Z)PQR K SP(X, P, K))}
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.