plsql - SQL stored procedure with 3 tables -


I have the following tables here:.

What I have here:

I need to list all the projects and tasks related to a customer (customer number is given as parameter) at the beginning of the report The customer's name is shown after the first project that displays the project and name. For each project, show it under the job number (in ascending order), details, hours and start date. Follow the last work with the customer's total work and project fee, then do the same for each upcoming project for the customer. At the end of the report, give the total number of hours for all those tasks, as well as how many projects and tasks were reported.

I'm not sure how many processes do the work, so any help is appreciated. Thanks!

next project Any relationship of cursor is not defined between TASK and Either the other tables used in the cursor, so each row in TASK is being included in the project and all valid combinations of the customer. It is known as "joining the cartesian" and probably did not have it in your mind. To improve this you need to slightly improve the cursor:

  select the cursor nextproject p.pjno, c.custname, t.taskno, t.descrip, t.hrs, t. start_date from Work T, Project P, Customer C where C.custno = P.custno and p.custno = custnum and t.pjno = p.pjno; - Added   

whether it can fix all your problems, but it should take you with this assignment.

This is

Share and Enjoy

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -