Question: 1 . What is a Distributed Database? 2 . What are the advantages of using a Distributed Database? 3 . What are the types of

1. What is a Distributed Database?
2. What are the advantages of using a Distributed Database?
3. What are the types of Distributed Databases?
4. What is Data Replication in Distributed Databases?
5. What is Data Fragmentation in Distributed Databases?
6. What is Consistency in Distributed Databases?
7. What are some common challenges in Distributed Databases?
8. What is Two-Phase Commit (2PC) in Distributed Databases?
9. What is a Distributed Query Processor?
10. CREATE TABLE `customer`(
`Cust_id` int unsigned NOT NULL AUTO_INCREMENT,
`first_name` varchar(45) NOT NULL,
`last_name` varchar(45) NOT NULL,
`email` varchar(45) NOT NULL,
`phone_no` varchar(45) NOT NULL,
`hire_date` varchar(45) NOT NULL,
`job_id` varchar(45) NOT NULL,
`Salary` decimal(2,0) NOT NULL DEFAULT '0',
`Commission_pct` decimal(2,0) NOT NULL,
`Manager_id` int NOT NULL,
`Dept_id` int DEFAULT NULL,
PRIMARY KEY (`Cust_id`,`email`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
*** create a table using the above syntax
***** insert into the table 5 records
A. From the following table, write a SQL query to find those employees who receive a higher salary than the employee with ID 163. Return first name, last name.
B. From the following table, write a SQL query to find out which employees have the same designation as the employee whose ID is 169. Return first name, last name, department ID and job ID.
C. From the following table, write a SQL query to find those employees whose salary matches the lowest salary of any of the departments
D. From the following table, write a SQL query to find those employees who earn more than the average salary. Return employee ID, first name, last name.
E. From the following table, write a SQL query to find those employees who report to that manager whose first name is Payam. Return first name, last name, employee ID and salary.
F. From the following tables, write a SQL query to find all those employees who work in the Finance department. Return department ID, name (first), job ID and department name.
G. From the following table, write a SQL query to find the employee whose salary is 3000 and reporting persons ID is 121. Return all fields.
H. From the following table, write a SQL query to find those employees whose ID matches any of the numbers 134,159 and 183.
I. From the following table, write a SQL query to find those employees whose salary is in the range of 1000, and 3000(Begin and end values have included.). Return all the fields.
J. From the following table and write a SQL query to find those employees whose salary falls within the range of the smallest salary and 2500. Return all the fields.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!