Creates a user-defined database role named orderentry

Assignment Help Database Management System
Reference no: EM131066989

Lab Assignment

Exercise

1. Write a script that creates a user-defined database role named OrderEntry in the MyGuitarShop database. Give INSERT and UPDATE permission to the new role for the Orders and OrderItems table. Give SELECT permission for all user tables.

2. Write a script that (1) creates a login ID named "RobertHalliday" with the password "HelloBob"; (2) sets the default database for the login to the MyGuitarShop database; (3) creates a user named "RobertHalliday" for the login; and (4) assigns the user to the OrderEntry role you created in exercise 1.

3. Write a script that uses dynamic SQL and a cursor to loop through each row of the Administrators table and (1) create a login ID for each row in that consists of the administrator's first and last name with no space between; (2) set a temporary password of "temp" for each login; (3) set the default database for the login to the MyGuitarShop database; (4) create a user for the login with the same name as the login; and (4) assign the user to the OrderEntry role you created in exercise 1.

4. Using the Management Studio, create a login ID named "RBrautigan" with the password "RBra9999," and set the default database to the MyGuitarShop database. Then, grant the login ID access to the MyGuitarShop database, create a user for the login ID named "RBrautigan", and assign the user to the OrderEntry role you created in exercise 1.

Note: If you get an error that says "The MUST_CHANGE option is not supported", you can deselect the "Enforce password policy" option for the login ID.

5. Write a script that removes the user-defined database role named OrderEntry. (Hint: This script should begin by removing all users from this role.)

6. Write a script that (1) creates a schema named Admin, (2) transfers the table named Addresses from the dbo schema to the Admin schema, (3) assigns the Admin schema as the default schema for the user named RobertHalliday that you created in exercise 2, and (4) grants all standard privileges except for REFERENCES and ALTER to RobertHalliday for the Admin schema.

Attachment:- Attachments.rar

Reference no: EM131066989

Questions Cloud

Create method called left that accepts a array of characters : Create a method called left that accepts an array of characters and the number of characters to return.
Summarise the impact of the interventions : Discuss the impact of TWO successful public health primary prevention interventions. You are expected to: briefly introduce the issue, population and population group; describe the interventions, summarise the impact of the interventions
Synthesize articles that focus on the question : In units 3 and 4, you will be asked to synthesize articles that focus on the question, "should the college athlete get paid?" Please watch this video from the CNN show Crossfire and respond to the following reflection:
Content to be understandable by your audience : 1. Mention and fully explain 4 ways that you can get a better attention from your audience during a speech. 2. Explain how can you as a presenter (say in your video) organize its content to be understandable by your audience.
Creates a user-defined database role named orderentry : Write a script that creates a user-defined database role named OrderEntry in the MyGuitarShop database. Give INSERT and UPDATE permission to the new role for the Orders and OrderItems table. Give SELECT permission for all user tables.
Brief opening scene : The purpose of the scene will be to clue the audience that this will be a modernist movie. Explain your ideas about what you would include in this brief opening scene.
Different cultures and times : Why is Austen's novel still so popular, with people returning to the story and adapting it to different cultures and times? What is it about her characters, their relationships, and her writing that has enduring resonance? Offer compelling reasons..
What is the magnitude of the friction force : what is the magnitude of the friction force opposing the motion of the block?
How the sensors and microprocessor interact to detect : A burglar alarm system uses pressure sensors and acoustic (sound) sensors to detect the presence of an intruder. A microprocessor is used to monitor and control the whole system. A keypad is used to key in a 4-digit PIN that either activates or d..

Reviews

Write a Review

Database Management System Questions & Answers

  Draw relational schema and show functional dependencies

Draw relational schema and show functional dependencies Comprehensive schema that shows existing PK and all functional, partial and transitive dependencies Detailed schema that shows existing PK and most functional, partial and transitive dependen..

  Possible areas of investigation for poster projects

Tentative list of possible areas of investigation for poster projects - Poster projects must be intended as an opportunity for student groups to investigate data mining/computational/statistical simulation problems and applications that interests ..

  Determine the steps in development of an effective entity

Determine the steps in the development of an effective Entity Relationship Model (ERM) Diagram and determine the possible iterative steps / factors that one must consider in this process with consideration of the HR core functions and responsibili..

  Demonstrate operating system troubleshooting techniques

Imagine you are a senior systems administrator who has recently been given the task to help improve security of your company's IT infrastructure after a series of network security breaches.

  What is the purpose of a database driver

what is the purpose of a database driver in terms of what it connects and What are some other examples of Database Drivers out there for the J2EE and .NET Platforms?

  Designing and documenting your system

Create a document named: surnameStudentIDAssign1.doc .  In your document, you must include the following section headings:  System Overview, Class Diagram, Class Descriptions, Testing.

  Create a report which identifies five most expensive bicycle

Create a report which identifies five most expensive bicycles. The report must list bicycles in descending order from most expensive to lease expensive, the quantity on hand for each, and the markup percentage for each.

  Design a database for a small medical practice

Narrative description of the "medical practice" database assignment: Design a database for a small medical practice with several physicians. The purpose of the database is to support the administrative functions such as billing, scheduling and pat..

  Part 1 true or false please explain why 1 sql structured

part 1 true or false please explain why. 1 sql structured query language is both ddl data definition language and dml

  Design supermarket management system

Design supermarket management system with it's problem definition

  Determine an effective sampling online database

Select a company from one of the Rasmussen online databases, such as Hoover's, Mergent Online, or the Harvard Business School library. Build a set of at least 40 effective measurement questions keeping in mind the content, participants and the out..

  Database and programming design

Database and Programming Design

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