ComputerScienceExpert

(11)

$18/per page/

About ComputerScienceExpert

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Applied Sciences,Calculus See all
Applied Sciences,Calculus,Chemistry,Computer Science,Environmental science,Information Systems,Science Hide all
Teaching Since: Apr 2017
Last Sign in: 103 Weeks Ago, 2 Days Ago
Questions Answered: 4870
Tutorials Posted: 4863

Education

  • MBA IT, Mater in Science and Technology
    Devry
    Jul-1996 - Jul-2000

Experience

  • Professor
    Devry University
    Mar-2010 - Oct-2016

Category > Programming Posted 28 Apr 2017 My Price 9.00

Using SQL and Northwind Database

Using SQL and Northwind Database

1. Write a simple trigger that only prints a message stating that a row in the customers table has been updated and that fires only 
upon the execution of an update statement on the customers table.
2. Create a trigger that will run instead of the Update statement on the Suppliers table.  It will 
fire when an Update statement is executed against the Suppliers table and will an error message saying:   
"Updating information in this table is not allowed"

Include a statement that will fire your trigger and also a statement to drop your trigger. 
(Hints:  There is such a thing as an "instead of trigger". Include a statement that will fire your trigger and also a statement to drop your trigger. 

3.

Northwind management is concerned that someone is updating and deleting products without following proper 
procedures. You are asked to provide a log of all future UPDATES and DELETES performed on the products table. Unfortunately
the products table does not store this information. You decide to create a log table and a trigger that will load this log table with the productid,
the date and the user of the deleted or updated product.
********************************************
The user can be obtained like this:
Declare @User varchar(20)
Select @User = System_User
Include a statement that will fire your trigger and also a statement to drop your trigger.
4. create a stored procedure called "uspListAllUserTables" that will print
the names of all tables in the sys.Objects table that are user tables (ie., type = 'U').  (Hint: you will not need to 
return a table object - just using the print statement within the sproc will print out the tables)

Include a statement to execute your stored procedure and be sure to test it to ensure it works.

Answers

(11)
Status NEW Posted 28 Apr 2017 06:04 AM My Price 9.00

-----------

Attachments

file 1493359997-Solutions file 2.docx preview (51 words )
H-----------ell-----------o S-----------ir/-----------Mad-----------am ----------- Th-----------ank----------- yo-----------u f-----------or -----------you-----------r i-----------nte-----------res-----------t a-----------nd -----------buy-----------ing----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n. -----------Ple-----------ase----------- pi-----------ng -----------me -----------on -----------cha-----------t I----------- am----------- on-----------lin-----------e o-----------r i-----------nbo-----------x m-----------e a----------- me-----------ssa-----------ge -----------I w-----------ill----------- be----------- qu-----------ick-----------ly -----------onl-----------ine----------- an-----------d g-----------ive----------- yo-----------u e-----------xac-----------t f-----------ile----------- an-----------d t-----------he -----------sam-----------e f-----------ile----------- is----------- al-----------so -----------sen-----------t t-----------o y-----------our----------- em-----------ail----------- th-----------at -----------is -----------reg-----------ist-----------ere-----------d o-----------n -----------THI-----------S W-----------EBS-----------ITE-----------. ----------- Th-----------ank----------- yo-----------u -----------
Not Rated(0)