Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Required Reading: Chapter 8 , 1 1 , 1 4 Write SQL statements for the following steps on the Sample database ( textbook example database
Required Reading: Chapter Write SQL statements for the following steps on the Sample database textbook example databasethe version which doesnt declare any constraints: a Create a stored procedure called insertRecord that takes three parameters as input start value, increment amount, and no of records. it inserts no of records rows in the employee table. The value of the empno column should start with the start value, and for the rest of the rows empno will be increment by the increment amount. All values of the columns emplname empfname, and deptno should be set to 'Jane', 'Smith', and d respectively. b Create a view that comprises the first and last names of all employees who entered their projects in the second half of the year c Create a view with the WITH CHECK OPTION clause that comprises the first and last names of all employees whose employee number is less than After that, use the view to insert data for a new employee named Kohn with the employee number who works for the dement d d With the help of triggers, define the referential integrity for the primary key of the project table, the projectno column, which is the foreign key of the workson table. pointspoints
Required Reading: Chapter
Write SQL statements for the following steps on the Sample database textbook example databasethe
version which doesnt declare any constraints:
a Create a stored procedure called insertRecord that takes three parameters as input start value,
increment amount, and no of records. it inserts no of records rows in the employee table. The value
of the empno column should start with the start value, and for the rest of the rows empno will be
increment by the increment amount. All values of the columns emplname empfname, and
deptno should be set to 'Jane', 'Smith', and d respectively.
b Create a view that comprises the first and last names of all employees who entered their projects in
the second half of the year
c Create a view with the WITH CHECK OPTION clause that comprises the first and last names of all
employees whose employee number is less than After that, use the view to insert data for a
new employee named Kohn with the employee number who works for the dement d
d With the help of triggers, define the referential integrity for the primary key of the project table, the
projectno column, which is the foreign key of the workson table.
pointspoints
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started