1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
uysha [10]
3 years ago
8

Create a stored procedure named prc_inv_amounts to update the INV_SUBTOTAL, INV_TAX, and INV_TOTAL. The procedure takes the invo

ice number as a parameter. The INV_SUBTOTAL is the sum of the LINE_TOTAL amounts for the invoice, the INV_TAX is the product of the INV_SUBTOTAL and the tax rate (8 percent), and the INV_TOTAL is the sum of the INV_SUBTOTAL and the INV_TAX.
Computers and Technology
1 answer:
vova2212 [387]3 years ago
7 0

Answer:

The procedure in SQL is created as follows

Explanation:

--creating the procedure

CREATE OR REPLACE PROCEDURE prc_inv_amounts (W_IN IN NUMBER)

AS

--defining variables

W_CK NUMBER := 0;

W_SUBT NUMBER := 0;

W_TAX NUMBER := 0;

BEGIN

--Authentication process of the invoice

SELECT COUNT(*) INTO W_CK FROM INVOICE WHERE INV_NUMBER := W_IN;

--Transaction confirmation

IF W_CK = 1 THEN

SELECT SUM(LINE_TOTAL) INTO W_SUBT FROM LINE

WHERE

--checking the invoice for the desired invoice number

LINE.INV_NUMBER = W_IN;

W_TAX :=W_SUBT * 0.08;

--updating the invoice

UPDATE INVOICE

--setting the new values

SET INV_SUBTOTAL = W_SUBT,

INV_TAX = W_TAX,

INV_TOTAL =W_SUBT + W_TAX

WHERE INV_NUMBER = W_IN;

--ending the if statement

END IF;

--ending the procedure

END;

You might be interested in
What are comments meant to do?
docker41 [41]
Comment<span> (computer programming) ... In computer programming, a </span>comment<span> is a programmer-readable explanation or annotation in the source code of a computer program. They are added with the purpose of making the source code easier for humans to understand, and are generally ignored by compilers and interpreters.</span>
8 0
3 years ago
The operation of an enable input on a multiplexer chip is.
Oxana [17]

Answer:

is used to activate the chip.

Explanation:

when enable is high the chip works (ACTIVE), when enable is low the chip does not work (MEMORY).

5 0
3 years ago
The emergence of MP3 (iPod) technology is an example of creative destruction because a. It is less expensive than compact discs
Katen [24]

Answer:

The emergence of MP3 (iPod) technology is an example of creative destruction because it has b. Replaced compact discs as a technology used for the storage and transfer of music.

Explanation:

Creative destruction refers to the process whereby a new technology/product replaces the one before it. The MP3 technology replaced compact discs because people started using MP3 files to transfer and store music since it was less expensive and files could be transferred easily. MP3 files could be transferred over Bluetooth and they required less storage space. Whereas, a compact disc required more space and costed more as well. So, MP3 technology replaced compact discs.

The emergence of MP3 (iPod) technology is an example of creative destruction because it has b. Replaced compact discs as a technology used for the storage and transfer of music.

8 0
3 years ago
Gps receivers are commonly used by individuals to determine their geographic location while hiking and to obtain driving directi
soldier1979 [14.2K]
I think it is true also.
7 0
4 years ago
Choose two technologies that you think would help the company meet its goals. Then fill in the chart below to compare the techno
elena55 [62]

Answer:

Good luck

Explanation:

Laptop and iPad

laptop because you can open many pages and tabs to help you multitask your goals

and iPad because most free business would be on an iPad and apps are cheap and would help you focus/help you work harder

7 0
3 years ago
Read 2 more answers
Other questions:
  • A(n) ________ network is a computer network that spans a relatively small area, allowing all computer users to connect with each
    14·1 answer
  • When a process becomes digital, it often becomes cheaper and the workflow becomes simpler. True False
    5·2 answers
  • A. True <br> b. False: variables represent storage locations in the computer's memory.
    13·1 answer
  • You want to multiply 50 in cell D3 by 8.90 in cell E3. Which formula should you use?
    11·1 answer
  • An algorithm is defined as a well-ordered collection of unambiguous and effectively computable operations that when executed pro
    10·1 answer
  • You are using the grep command, but it is only searching through files in your immediate home directory. What option enables you
    7·1 answer
  • Write a function named remove_duplicates that takes a list (of numeric and/or string values) and returns a new list with only th
    9·1 answer
  • Implement a function with signature barGraph(w, h, data) which creates and returns a cs1graphics.Canvas instance that has width
    9·1 answer
  • List six common raster image file types.
    9·1 answer
  • the ratio of length, breadth and height of a room is 4:3:1. If 12m^3 air is contained in a room, find the length , breadth and h
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!