subject

Enhance your solution to exercise 3 so it uses a substitution variable to set a bind variable that you use to determine what the minimum balance due should be for the invoices that the SELECT statement is going to retrieve. You should also use this bind variable to display a heading like this before the list of invoices: You are using the bind variable to set the balance due minimum. In this case 2000 is not a hard coded value but is set using a bind variable. Invoice amounts greater than or equal to $2,000 where 2,000 is the value of the bind variable. SET SERVEROUTPUT ON;
DECLARE
CURSOR invoices_cursor IS
SELECT vendor_name, invoice_number, invoice_total - payment_total - credit_total AS balance_due
FROM ap. vendors v INNER JOIN ap. invoices i
ON v. vendor_id = i. vendor_id
WHERE invoice_total - payment_total - credit_total >= 5000
ORDER BY balance_due DESC;
invoice_row invoices_copy%ROWTYPE;
BEGIN
FOR invoice_row IN invoices_cursor LOOP
DBMS_OUTPUT. PUT_LINE(to_char(invoice_row. balance_due, '$99,999.99') || ' ' || invoice_row. invoice_number || ' ' || invoice_row. vendor_name);
END LOOP;
END;

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 00:40
Write a function 'music_func' that takes 3 parameters -- music type, music group, vocalist -- and prints them all out as shown in the example below. in case no input is provided by the user, the function should assume these values for the parameters: "classic rock", "the beatles", "freddie mercury". for example: input: alternative rock,pearl jam,chris cornell output: the best kind of music is alternative rock the best music group is pearl jam the best lead vocalist is chris cornell note: the print statements will go inside the for example: print("the best kind of music is"
Answers: 2
question
Computers and Technology, 22.06.2019 09:00
Howard is designing a chair swing ride. the swing ropes are 5 meters long, and in full swing they tilt in an angle of 29° outside chairs to be 2.75 m above the ground in full swing.
Answers: 1
question
Computers and Technology, 22.06.2019 14:50
Drag each label to the correct location on the image list the do’s and don’ts of safeguarding your password. a. keep yourself logged in when you leave your computer.b. don’t write your password down and leave it where others can find it.c. share your password with your friends.d.each time you visit a website,retain the cookies on your computer.e. use a long password with mixed characters.1. do's 2. don'ts
Answers: 2
question
Computers and Technology, 23.06.2019 04:31
Selling a product through an electronic medium is
Answers: 1
You know the right answer?
Enhance your solution to exercise 3 so it uses a substitution variable to set a bind variable that y...
Questions
question
English, 26.02.2021 20:50
question
Mathematics, 26.02.2021 20:50
question
Mathematics, 26.02.2021 20:50
question
Mathematics, 26.02.2021 20:50
question
Mathematics, 26.02.2021 20:50
question
Mathematics, 26.02.2021 20:50
question
Mathematics, 26.02.2021 20:50
question
Chemistry, 26.02.2021 20:50
Questions on the website: 13722360