Script below to create an updateable

Assignment Help PL-SQL Programming
Reference no: EM13166912

Use the script below to create an updateable view named balance_due_view. Then, create and test an INSTEAD OF trigger named invoices_instead_of_insert that lets the user update the columns in the view by directly updating the Invoices table. Within this trigger, you can call the stored procedure named insert_invoice that's created by the script for figure 15-5

CREATE OR REPLACE VIEW balance_due_view AS

SELECT vendor_name, invoice_number,

invoice_total, payment_total, credit_total,

invoice_total - payment_total - credit_total AS balance_due

FROM vendors JOIN invoices ON vendors.vendor_id = invoices.vendor_id

WHERE invoice_total - payment_total - credit_total > 0;

Reference no: EM13166912

Questions Cloud

Write a compete pl/sql program to display the staffno : Write a compete PL/SQL program to display the StaffNo,
Commands that you would use to create a 7x7 matrix : Show the unix/linux commands that you would use to create a 7x7 matrix of alternating entries of 1's and 0's. It should look like this
Project that uses interactions to develop the system : on a project that uses interactions to develop the system, in which interation does systems design begin? explain why
What are the formulas for these worst case time complexities : What are the formulas for these Worst Case Time Complexities?
Script below to create an updateable : Use the script below to create an updateable view named balance_due_view. Then, create and test an INSTEAD OF trigger named invoices_instead_of_insert that lets the user update the columns in the view by directly updating the Invoices table.
Asks a user to enter the radius of a circle : Write a program that asks a user to enter the radius of a circle, and calcualtes the area and the circumference. The program should be written using the following methods.
Phil maintains a blog online : Phil maintains a blog online. What do you do to check that his blog is not revealing sensitive company information? Is he allowed to maintain his blog during work hours
Fluid mechanics : Consider a two-dimensional velocity ?eld V~ = aˆi + by2ˆj, where a = 1 m/s and b = 2 m?1s-1
Use numbers 0 through 23 to represent hours : Write a C function seconds_since_jan1() that takes the time as six integer arguments (year, month, day, hour,minute, and second) and returns the number of seconds since the beginning of the year. Use numbers 1 through 12 to represent months. Use numb..

Reviews

Write a Review

PL-SQL Programming Questions & Answers

  Display all the lastnames from the customers table

Display all the LastNames from the Customers table and any associated OrdersIDs from the Orders Table. Show the LastName even if they do not have any associated orders. Order the results by LastName in ascending order.

  Create report using wizard or based on sql query

Create a report using the wizard or based on an SQL query that that shows Courses that instructors are approved to teach. Show Course Number, First Name, and Last Name of Instructor.

  Write programme in oracle to make employee table

List the employee_id and employee_name of the employees form the l_employees table with the top 4 credit limits.

  Script that creates and calls a stored

Write a script that creates and calls a stored procedure named spInsertProduct that inserts a row into the Products table. This stored procedure should accept five parameters

  Write an update statement that modifies the row

Write an UPDATE statement that modifies the row you just added to the Categories table. This statement should change the ProductName column to "Woodwinds", and it should use the CategoryID column to identify the row.

  Write a pl-sql block

Write a PL/SQ block - Select the average salary of all employees in department number 20.

  Provide four queries to answer questions asked by end users

Explain how you will go about developing this database. Provide at least four queries that answer some of the questions asked by the end users.

  Write select statement to return those rows with due balance

Write SELECT statement which returns those rows with the balance due greater than 1000. Sort result set by InvoiceTotal, with largest invoice first.

  Write a perl subroutine for temperature conversion

Write a perl subroutine for temperature conversion named ' convert_temp '. It should be able to handle both Fahrenheit to Celsius conversions as well as Celsius to Fahrenheit conversions.

  Pl-sql block to display last name and salary

Write a PL/SQL block that displays the last name and salary of the following people. Each of these can be done separately as PL/SQL, first to test and get the output lines then encapsulated.

  Write down sql needed to create employee table

Write down SQL needed to create employee table containing the following data: employeeID, text, length of 5, primary key lastName, text, length of 25

  Convert requirement to logic and then to sql

Prepare the SQL query for each of given requirements. Convert requirement to logic, then to SQL. Illustrate the names of all products which have been sold.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd