Homework help
$30-5000 USD
Betalt ved levering
This is to done in SQLJ programming. (1) Recreate the P table as an object table. Create an ACTIVES table that contains all the S columns, as well as an SP column that is a nested table of references to P records (namely, the P records that are supplied by that supplier). Load P and ACTIVES as follows: Load P and ACTIVES as follows: _____________________________ |P#|PNAME|COLOR|WEIGHT|CITY | |__|_____|_____|______|______| |P1|Nut |Red | 12 |London| |P2|Bolt |Green| 17 |Paris | |P3|Screw|Blue | 17 |Rome | |P4|Screw|Red | 14 |London| |P5|Cam |Blue | 12 |Paris | |P6|Cog |Red | 19 |London| |____________________________| __________________________________________________________ |S# |SNAME|STATUS|CITY |SP | |___|_____|______|_______|________________________________| |S1 |Smith| 20 |London |references for P1,P2,P3,P4,P5,P6| | | | | |records | |S2 |Jones| 10 |Paris |references for P1,P2 records | |S3 |Blake| 30 |Paris |reference for P2 record | |S4 |Clark| 20 |London |references for P2,P4,P5 records | |_________________________________________________________| Code the following: (a) a select statement that prints the entire part records for parts supplied by S3. (b) a select statement that prints all snum, pnum pairs such that both the indicated supplier and the indicated part are in London and the indicated supplier supplies the indicated part. (c) a select statement that prints the snums of suppliers who supply a blue part that is stored in Paris. (d) (i) a delete statement that deletes the P4 part from the S1's SP set. (ii) a select statement that prints the entire P records that are referenced by S1's SP set. (2) Redo (1), implementing SP as a varray of P records. The deletion in (d)(i) is accomplished by a PL/SQL block that contains a select into statement and an update statement. (d)(ii) is still accomplished by a stand-alone select statement that is not contained in a PL/SQL block. (3) Redo (1), implementing SP as a varray of references to P records. (4) Redo (1), implementing SP as a varray of P#'s.
## Deliverables
Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. Complete copyrights to all work purchased.
## Platform
unix, Oracle SQLPLUS
## Deadline information
Must be completed on time, no delays please.
Projekt ID: #2847590