Create a sequence that generates integers starting


Assignment: Database Development- Sequence Objects

Watch this YouTube video: "SQL Tutorial - Sequence Objects".

Complete the following tasks using DDL & DML commands, NOT THE GUI in the Microsoft SQL Server Management Studio.

• Create a sequence for populating the Customer# column of the DB1.CASTEEL.CUSTOMERS table. When setting the start and increment values, keep in mind that data already exists in this table. The options should be set to not cycle the values and not cache any values, and no minimum or maximum values should be declared.

o Sequence Goes Here.
o Screen Shot Goes Here

• Add a new customer row to the DB1.CASTEEL.CUSTOMERS table by using the sequence created in Question 1. The only data currently available for the customer is as follows:

o last name = Shoulders
o first name = Frank
o zip = 23567

o Query Goes Here.
o Screen Shot Goes Here

• Create a sequence that generates integers starting with the value 5. Each value should be three less than the previous value generated. The lowest possible value should be 0, and the sequence shouldn't be allowed to cycle. Name the sequence MY_FIRST_SEQ.

o Sequence Goes Here.
o Screen Shot Goes Here

• Issue a SELECT statement that displays NEXTVAL for MY_FIRST_SEQ three times. What causes the error on the third SELECT?

o Select Goes Here.
o Select Goes Here.
o Select Goes Here.
o Screen Shot Goes Here

• Change the setting of MY_FIRST_SEQ so that the minimum value that can be generated is -1000.

o Alter Sequence Goes Here.
o Screen Shot Goes Here.

Format your assignment according to the following formatting requirements:

o The answer should be typed, using Times New Roman font (size 12), double spaced, with one-inch margins on all sides.

o The response also includes a cover page containing the title of the assignment, the student's name, the course title, and the date. The cover page is not included in the required page length.

o Also include a reference page. The Citations and references must follow APA format. The reference page is not included in the required page length.

Solution Preview :

Prepared by a verified Expert
Computer Engineering: Create a sequence that generates integers starting
Reference No:- TGS03111967

Now Priced at $35 (50% Discount)

Recommended (95%)

Rated (4.7/5)