This topic contains a solution. Click here to go to the answer

Author Question: Explain the features of the following code.CREATE PROCEDURE usp_StudentLogInstudentKey nchar(10)ASIF ... (Read 35 times)

ap345

  • Hero Member
  • *****
  • Posts: 537
Explain the features of the following code.CREATE PROCEDURE usp_StudentLogInstu dentKey nchar(10)ASIF EXISTS(SELECT FROM studentWHERE studentKey=studentKey)BEGINSELECT studentLastNameFROM StudentWHERE Studentkey=studentKeyEND
 
  What will be an ideal response?

Question 2

Explain how views and stored procedures could be used to help ensure the security of a database.
 
  What will be an ideal response?



Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
Marked as best answer by a Subject Expert

sokh

  • Sr. Member
  • ****
  • Posts: 357
Answer to Question 1

This code creates a stored procedure called usp_StudentLogIn. It asks for a parameter StudentKey. Next it checks to see if that studentKey exists in the student table. If it does it returns the students name.

Answer to Question 2

Views present the user with a view of the data that is appropriate to their use of the database. Views can be used to hide the underlying structure of the tables and columns. This can help prevent a disgruntled user from attacking the underlying structure. Stored procedures can be used to capture INSERTS, UPDATES, and DELETES and make sure they occur safely.




ap345

  • Member
  • Posts: 537
Reply 2 on: Jul 7, 2018
Thanks for the timely response, appreciate it


Missbam101

  • Member
  • Posts: 341
Reply 3 on: Yesterday
Gracias!

 

Did you know?

The toxic levels for lithium carbonate are close to the therapeutic levels. Signs of toxicity include fine hand tremor, polyuria, mild thirst, nausea, general discomfort, diarrhea, vomiting, drowsiness, muscular weakness, lack of coordination, ataxia, giddiness, tinnitus, and blurred vision.

Did you know?

More than 4.4billion prescriptions were dispensed within the United States in 2016.

Did you know?

You should not take more than 1,000 mg of vitamin E per day. Doses above this amount increase the risk of bleeding problems that can lead to a stroke.

Did you know?

The top 10 most important tips that will help you grow old gracefully include (1) quit smoking, (2) keep your weight down, (3) take supplements, (4) skip a meal each day or fast 1 day per week, (5) get a pet, (6) get medical help for chronic pain, (7) walk regularly, (8) reduce arguments, (9) put live plants in your living space, and (10) do some weight training.

Did you know?

The familiar sounds of your heart are made by the heart's valves as they open and close.

For a complete list of videos, visit our video library