Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Note that the EMPLOYEES and the DEPARTMENTS tables refereed in the following questions are the ones in the HR account. Q1: What is a view?

Note that the

EMPLOYEES

and the

DEPARTMENTS

tables refereed in the following questions are the ones in

the

HR

account.

Q1: What is a view?

Q2: What is the difference between a view and a table?

Q3: What is a view used for?

Q4: Give the SQL statement that creates a view called

M10V01

, which consists of first name, last name,

salary, and hire date of employees with salary more than 3000 and hired in 2004.

Q5: Give the SQL statement that creates a view called

M10V02

, which consists of first name, last name,

salary, and hire date of employees with first name starts and ends with A and a respectively.

Q6: Give the SQL statement that creates a view called

M10V03

, which consists of first name, last name,

department id of employees

LEFT

OUTER

JOIN

on table

DEPARTMENTS

using the

MANAGER

ID

as

the join condition.

Q7: Give the SQL statement that finds the average salary for employees via

M10V01

.

Q8: Give the SQL statement that increases the salary of Jason Mallin by 20% via

M10V01

.

Q9: Give the SQL statement that counts the number of employees via

M10V02

.

Q10: Give the SQL statement that deletes

M10V03

.

Q11: What is a materialized view?

Q12: What is the difference between a view and a materialized view?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design And SQL For DB2

Authors: James Cooper

1st Edition

1583473572, 978-1583473573

Students also viewed these Databases questions

Question

=+ How do you know?

Answered: 1 week ago

Question

Describe Table Structures in RDMSs.

Answered: 1 week ago