Consider the table Customers(CustomerID, Name, Address, CreditLimit) You want to automatically update the credit limit of...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Consider the table Customers(CustomerID, Name, Address, CreditLimit) You want to automatically update the credit limit of the customer 5 using the following update statement. UPDATE customers SET credit limit - 5000 WHERE customer_id = 5: The developer has written the following trigger to automatically update CREATE OR REPLACE TRIGGER customers_credit_policy_trg AFTER INSERT OR UPDATE ON customers FOR EACH ROW DECLARE 1 max credit customers.credit_limit TYPE: BEGIN SELECT MIN (credit_limit) - S INTO 1 max credit FROM customers WHERE credit limit > 0: IF 1_max_credit < NEW.credit_limit THEN UPDATE customers SET credit limit=1_max_credit WHERE customer_id INEW.customer_id: END 17: END: Is there anything wrong that the developer is doing? The developer is not doing anything wrong. After the trigger is fired, if the credit is greater than 5 times of the lowest non-zero credit, the system automatically assigns this credit to the customer. The update statement is incorrect. The trigger is incorrect. The developer is not doing anything wrong. After the trigger is fired, customer 5's credit limit will be increased. Consider the table Customers(CustomerID, Name, Address, CreditLimit) You want to automatically update the credit limit of the customer 5 using the following update statement. UPDATE customers SET credit limit - 5000 WHERE customer_id = 5: The developer has written the following trigger to automatically update CREATE OR REPLACE TRIGGER customers_credit_policy_trg AFTER INSERT OR UPDATE ON customers FOR EACH ROW DECLARE 1 max credit customers.credit_limit TYPE: BEGIN SELECT MIN (credit_limit) - S INTO 1 max credit FROM customers WHERE credit limit > 0: IF 1_max_credit < NEW.credit_limit THEN UPDATE customers SET credit limit=1_max_credit WHERE customer_id INEW.customer_id: END 17: END: Is there anything wrong that the developer is doing? The developer is not doing anything wrong. After the trigger is fired, if the credit is greater than 5 times of the lowest non-zero credit, the system automatically assigns this credit to the customer. The update statement is incorrect. The trigger is incorrect. The developer is not doing anything wrong. After the trigger is fired, customer 5's credit limit will be increased.
Expert Answer:
Answer rating: 100% (QA)
The detailed answer for the above question is provided below The correct answer is option 3 The tr... View the full answer
Related Book For
Income Tax Fundamentals 2013
ISBN: 9781285586618
31st Edition
Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill
Posted Date:
Students also viewed these programming questions
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
Googles ease of use and superior search results have propelled the search engine to its num- ber one status, ousting the early dominance of competitors such as WebCrawler and Infos- eek. Even later...
-
This exercise investigates the way in which conditional independence relationships affect the amount of information needed for probabilistic calculations. a. Suppose we wish to calculate P (he1, e2)...
-
person claims to have ESP (extrasensory perception). A coin is tossed 16 times, and each time, the person is asked to predict in advance whether the coin will land heads or tails. The person predicts...
-
If possible, give an example of a homomorphism : R R' where R and R' are rings with unity 1 0 and 1' 0', and where (1) 0' and (1) 1'.
-
In Example 8.1, the mosquito has an inertia of \(0.1 \mathrm{~g}\) and is initially at rest, while the bus, with an inertia of \(10,000 \mathrm{~kg}\), has an initial speed of \(25 \mathrm{~m} /...
-
1. Do you believe that auditors should be held liable for failing to discover fraud in situations such as ZZZZ Best, where top management goes to great lengths to fool the auditors? Answer this...
-
a) A real estate contract is a contract between parties for the purchase and sale, exchange, or other conveyance of real estate. The sale of land is governed by the laws and practices of the...
-
Differentiate between accelerator principle of investment and investment multiplier. Explain the determinants of induced investment in an economy. Given C=a+bY, explain "a" and "b" and then sketch...
-
When assets are exchanged to balance inventories, Multiple select question. the exchange will result in a gain or loss. the exchange does not represent earnings. the received assets are recorded at...
-
Discuss the role of scenario planning and probabilistic forecasting in market analysis, particularly in assessing the resilience of businesses to disruptive events and identifying strategic...
-
How do businesses employ advanced econometric models and data analytics techniques to conduct market analysis, incorporating factors such as demand elasticity, market segmentation, and competitive...
-
An example of a cost which would nSheridan Company used high and low data from June and July to determine its variable cost of $10 per unit. Additional information follows:ot be assigned to a...
-
A corporation called an outstanding bond obligation four years before maturity. At that time there was an unamortized discount of $1560000. To extinguish this debt, the company had to pay a call...
-
Formula's: 1. (x+y)(x-y) = x^2 - y^2 2. (x + y)^2 = x^2 + 2xy + y^2 3. (x-y)^2= x^2 -2xy + y^2 Which above formula would be used by the following problems? 1. [(a+b) - (c+d)][(a+b) + (c+d)] 2....
-
An interest bearing promissory note for 90 days at 5.6% p.a. has a face value of $120,000. If the note is discounted 20 days after the issue date at a rate of 6.8% p.a., calculate the amount of...
-
Frank, age 35, and Joyce, age 34, are married and file a joint income tax return for 2012. Their salaries for the year total $83,000 and they have taxable interest income of $4,000. They have no...
-
Joan is a self-employed attorney in New York City. Joan took a trip to San Diego, CA, primarily for business, to consult with a client and take a short vacation. On the trip, Joan incurred the...
-
Carol Harris, Ph.D, CPA, is a single taxpayer and she lives at 674 Yankee Street, Durham, NC 27409. Her Social Security number is 793-52-4335. Carol is an Associate Professor of Accounting at a local...
-
What does the Richter scale measure?
-
Where do earthquakes occur?
-
Climates farther from the equator usually have (a) lower average temperatures. (b) higher solar intensity. (c) more precipitation. (d) more water.
Study smarter with the SolutionInn App