Question

You're building a database that tracks inventory & sales at the company you work for. Every...

You're building a database that tracks inventory & sales at the company you work for.

Every time a row is INSERTed into the OrderLines table, you need a process to be invoked that checks the inventory table to make sure the particular Product is in stock.if the product is out of stock, the Quantity on the row should be changed to 0 indicating there were non in stock for the Product.

You have chosen not to put this logic into a stored procedure because there is risk that rows may be inserted by not calling the stored procedure.

what type of object should you create?

A. A Trigger

B.a view

C. an index

d. a user-defined function.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer:trigger

The SQLtrigger are database objcts that are executed whenever an eventoccurs. Thus a SQLtrigger can be made to do required tasks whenever an insert staatement is executed.

Add a comment
Know the answer?
Add Answer to:
You're building a database that tracks inventory & sales at the company you work for. Every...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • You will develop an E-Commerce database used to maintain customers, products and sales information. You are...

    You will develop an E-Commerce database used to maintain customers, products and sales information. You are required to 1) gather and analyze requirements 2) design logical structure of the database 3) create stored procedures to develop the tables and insert the data 4) write SQL statements for data extraction and reporting. Throughout the course of this semester you have analyzed the requirements for an eCommerce database, designed and developed your database. As a class we have gone through the process...

  • Create SQL statements based on the given tables: Code to create the tables: CREATE DATABASE LAB...

    Create SQL statements based on the given tables: Code to create the tables: CREATE DATABASE LAB4DB; USE LAB4DB; CREATE TABLE CUSTOMER ( CUS_CODE int primary key, CUS_LNAME varchar(15), CUS_FNAME varchar(15), CUS_INITIAL varchar(1), CUS_AREACODE varchar(3), CUS_PHONE varchar(8), CUS_BALANCE float(8) ); INSERT INTO CUSTOMER VALUES('10010','Ramas','Alfred','A','615','844-2573','0'); INSERT INTO CUSTOMER VALUES('10011','Dunne','Leona','K','713','894-1238','0'); INSERT INTO CUSTOMER VALUES('10012','Smith','Kathy','W','615','894-2285','345.86'); INSERT INTO CUSTOMER VALUES('10013','Olowski','Paul','F','615','894-2180','536.75'); INSERT INTO CUSTOMER VALUES('10014','Orlando','Myron','','615','222-1672','0'); INSERT INTO CUSTOMER VALUES('10015','O''Brian','Amy','B','713','442-3381','0'); INSERT INTO CUSTOMER VALUES('10016','Brown','James','G','615','297-1228','221.19'); INSERT INTO CUSTOMER VALUES('10017','Williams','George','','615','290-2556','768.93'); INSERT INTO CUSTOMER VALUES('10018','Farriss','Anne','G','713','382-7185','216.55'); INSERT INTO CUSTOMER VALUES('10019','Smith','Olette','K','615','297-3809','0'); /*...

  • please use Java!! We are storing the inventory for our fruit stand in a hash table....

    please use Java!! We are storing the inventory for our fruit stand in a hash table. The attached file shows all the possible key/fruit combinations that can be inserted into your hash table. These are the real price lookup values for the corresponding fruit. Problem Description In this programming assignment, you will implement a hash table class fruitHash. Your hash table must include the following methods: 1) hashFunction(key) This method takes a key as an argument and returns the address...

  • You have recently become the CFO for Beta Manufacturing, a small cap company that produces auto parts

    EX16_XL_COMP_GRADER_CAP_AS - Manufacturing 1.6 Project Description:You have recently become the CFO for Beta Manufacturing, a small cap company that produces auto parts. As you step into your new position, you have decided to compile a report that details all aspects of the business, including: employee tax withholding, facility management, sales data, and product inventory. To complete the task, you will duplicate existing formatting, utilize various conditional logic functions, complete an amortization table with financial functions, visualize data with PivotTables, and lastly...

  • please use python and provide run result, thank you! click on pic to make it bigger...

    please use python and provide run result, thank you! click on pic to make it bigger For this assignment you will have to investigate the use of the Python random library's random generator function, random.randrange(stop), randrange produces a random integer in the range of 0 to stop-1. You will need to import random at the top of your program. You can find this in the text or using the online resources given in the lectures A Slot Machine Simulation Understand...

  • Cloud 9 - Continuing Case Sharon Gallagher and Josh Thomas have assessed the internal controls at...

    Cloud 9 - Continuing Case Sharon Gallagher and Josh Thomas have assessed the internal controls at Cloud 9 as being effective at an entity level. This means that, at a high level, the company demonstrates an environment where potential material misstatements are prevented or detected. Answer the following questions based on the information presented for Cloud 9 in the appendix to this text and the current and earlier chapters. You should also consider your answers to the case-study questions in...

  • Please read the article bellow and discuss the shift in the company's approach to genetic analysis....

    Please read the article bellow and discuss the shift in the company's approach to genetic analysis. Please also discuss what you think about personal genomic companies' approaches to research. Feel free to compare 23andMe's polices on research with another company's. Did you think the FDA was right in prohibiting 23andMe from providing health information? These are some sample talking points to get you thinking about the ethics of genetic research in the context of Big Data. You don't have to...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT