Answered step by step
Verified Expert Solution
Question
1 Approved Answer
1. Write the SQL statements to ereate database objects. la. Create a table with the details shown below: Table-Name: Doctors_Student_id [Example Doctors_12.J124] begin{tabular}{|1|1|1|} hline multicolumn{1}{[c]}{
1. Write the SQL statements to ereate database objects. la. Create a table with the details shown below: Table-Name: Doctors_Student_id [Example Doctors_12.J124] \begin{tabular}{|1|1|1|} \hline \multicolumn{1}{[c]}{ Column Name} &\multicolumn{1}{]c[}{ Data Type } & \multicolumn{1}{1c]}{ Constraint (Column tevel) } \ Thline Doctorio & Number(4) & Should not be empty and not repeated \hline DoctorName & Varchar2(25) & \hline Salary & Number(6) & Should be more than or equal to 5000 \hline \end{tabular) 1b. When do we use Column-level and Table-level Constraints? Explain with example each. 1c. Enter any two (2) records into the Doctors table. Id. Modify the Doctors table by applying the following constraints: \begin{tabular}{[1/1]} \hline Column Name & Constraint \hline Salary & Delete the constraint " \hline DoctorName & Should not be empty \hline \end{tabular) 2a. Create a view "View_Dept $6090^{-}$" which will display columns EmpNo, EName and Salary, by selecting the employee_id, First_Name and salary from Employees table, whose department_id is cither 60 or 90 or the First_name contains letter 'a'. Assign or set a constraint to control the access of data, by ensuring that modifications (DML operations) are not allowed. 2b. Explain the purpose of creating views in your own words. CS.VS.954
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