Scenario Questions: =================== 1) Write a query that we need to retrieve the names and salaries of employees from the "employees" table, but only for the those working in the finance department. creating the table: ------------------- create table employees ( employee_Id int, first_name varchar(50), last_name varchar(50), designation varchar(50), department varchar(50), salary decimal(10,2) ); -> to deal with whole numbers, oracle is providing another datatype is called as "int" -> to deal with decimal-point values (floats), we have "decimal" datatype. Syntax: decimal(precision, size); -> to retrieve: select first_name,last_name,salary from employees where department = 'finance'; ===================================== 2) Write a query that we need to add a new employee named 'John Doe' to the employees table with a salary of 50000 and department of 'HR'. insert into employees(employee_Id,first_name,lat_name,desination,department,salary) values(172839,'John','Doe','HR Manager','HR',50000); 3) Write a query to increase the salary of all employees in the IT department by 10%. update employees set salary = salary * 1.1 where department = 'IT'; 4) Write a query to filter employees with salaries between 30000 and 60000. select * from employees where salary >= 30000 and salary <= 60000; 5) Write a query to retrieve employees whose salaries are not 40000 select * from employees where salary != 40000; 6) Write a query to find employees whose names contains the letter 'a'. like operator: -------------- => when we want to perform the search operation using "regular expression", we can use "like" operator. select first_name, last_name from employees where first_name like '%a%';