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

Using the E-R Diagram below, how would I write this query in SQL? Find the cours

ID: 3717471 • Letter: U

Question

Using the E-R Diagram below, how would I write this query in SQL?

Find the course sets where their combination covers all the missing knowledge/skills for a person to pursue a pos_code. The considered course sets will not include more than three courses. If multiple course sets are found, list the course sets (with their course IDs) in the order of the ascending order of the course sets’ total costs.

Bryan Zheng Randy Phan Section Person Position PK c code takes PK per ld PK pos code emp_mode (required sll) pay rate PK year zip code complele date offered by format price ernail cate code phone hns skil has Knowledge Job_category PK e code PK k code PK cate code tite ks trle ks dosoription ks level title dosciptiorn pay range high pay range low (oore skill retail price Company PK comp id hires pimary secior NAICS

Explanation / Answer

The SQL query for the given problem is given below. As no ps_code is mention so i am assuming ps_code to be 'ps-101'.

Query-

SELECT c.c_code, c.title, c.level, c.description,k.ks_code, SUM(c.retail_price)
FROM Course c
INNER JOIN Knowledge k
ON c.c_code = k.c_code
INNER JOIN requires r
ON r.ks_code = k.ks_code
WHERE ps_code = 'ps-101'
GROUP BY c.c_code, c.title, c.level, c.description,k.ks_code
ORDER BY c.retail_price;

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