Question
I would greatly appreciate any help on this, this is an assignment in MySQL. Thank you in advance! 1) Faculty has decided to give all
I would greatly appreciate any help on this, this is an assignment in MySQL. Thank you in advance!
1) Faculty has decided to give all staff members a 5% raise. Create output as shown: Faculty id, first name, last name, salary and bonus salary column with raise;
2) Show all students where their home phone number is null ?
3) You want to know the annual salary of all faculty. How will you show that?
4) You want Oracle to show how old are you. Show syntax for how old are you?
5) I want all salaries of faculty to have a dollar sign and commas and period before decimal. How would you format that?
6) Display the faculty id, first name, last name, salary, but this time include another column called "Calculation" where salary will be divided by 1.55 and it will round the result to decimal places?
7) Write a SQL statement using the employees table and the ORDER BY clause that could retrive data in desceding order but only for employees id is below 125?
8) TO_CHAR command with column LOW and HIGH
Create a query that will format the DJs on Demand d_packages columns,low-rangeand high-range package costs, in the format $2500.00.
9) TO_CHAR command Ellen Abel is an employee who has received a $2,000 raise. Display her first name and last name, her current salary, and her new salary. Display both salaries with a $ and two decimal places. Label her new salary column AS New Salary.
10) TO_CHAR
Convert todays date to a format such as:Today is the Twentieth of March,TwoThousand Four
11) List the last names and birthdays of Global Fast Food Employees. Convertthebirthdates to character data in the Month DD, YYYY format. Suppress any leading zeros. (from f_staffs table);
12) Use ROUND then(ADD_MONTH command ( Display the days between January1 and December31.
13) First use ROUND for month, then year, then do the same but use TRUNC Using one statement,round today's date to the nearest month and nearest year and truncate it to the nearest month and nearest year. Use an alias for each column.
14) Because I have been working for Oracle since the beginning of 1996, I make more than $9000 per month. Because I make so much money, I don't get a commission
15) MONTHS_BETWEEN command Display the number of years between the Global Fast Foods employee Bob Millers birthday and today. Round to the nearest year. His id is 9? (from f_staffs)
16) NEXT_DAY command Whats the date of the next Friday after your birthday this year? Name the output, First Friday.
17) Using DUAL, write a statement that will convert 86.678 to 86.68.
18) Using DUAL,convert 73.892 to 73.8 ?
19) NEXT_DAY command
What is the next Friday six months from now? Label the column Future.
20) ADD_MONTHS command
What is the date 10 years or 120 months from now? Label the column Future.
21) Write a statement that will return the Oracle database employees employee ID and their starting hire dates between January 1, 1997 and today. Display the result ordered from most recently hired to the oldest.
22) TRUNC command
Display employee last_name and salary for those employees who work in department 80. Give each of them a raise of 5.333% and truncate the result to two decimal places.
23) Use the DUAL table to process the following numbers: 845.553 - round to one decimal place 30695.348 - round to two decimal places 30695.348 - round to -2 decimal places 2.3454 - truncate the 454 from the decimal place
24) Use the string Oracle Internet Academy to produce the following output: The Net column with words only: net
25) LENGTH command
What is the length of the stringOracle Internet Academy?
26) INSTR command Whats the position of I in Oracle Internet Academy?
27) USING RPAD command: Starting with the string Oracle Internet Academy,pad the string to produce: Oracle$$$Internet$$$Academy
28) Write a query to return the first character of the first name concatenated to the last_name, the salary, and the department id for employees working in department 20. Give the first expression an alias of Name. Use the EMPLOYEES table.
29) Write SELECT statement that will always return the last names in alphabetical order from employees table?
30) Examine the following query: SELECT last_name, job_id, salary FROM employees WHERE job_id = 'SA_REP' OR job_id = 'AD_PRES' AND salary >15000;
Which results could not have been returned from this query?
a. Joe Everyone,sales representative,salary 15000 b. Jane Hendricks,sales manager,salary 15500 c. Arnie Smithers, administration president, 20000 d. Jordan Lim,sales representative,salary 14000
31) Return all employees whose last names start with St.
32) I was hired by Oracle after May 1998 but before June of 1999. My salary is less than $8000 per month, and I have an en in my last name.
33) USE LAST DAY What is the last day of the month for June 2005? Use an alias for the output.
34) Write a statement that will return only the DJs on Demand CDs with years greater than 2000 but less than 2003. Display both the title and year.
35) Show faculty names, their salary and show salary bonus of 1000 for all faculty employees that where hired from 2000 only
36) Find all faculty which make their salary are no less then 2000 plus no more then 7000
37) Select all the students whose last names end with e, and change the heading of the column to show Names of Students.
38) Show all students id, first name, last name whose first name that doesn't start with second letter "e" ?
39) Show all faculty id, first name, last name, dob, but only dob before May 2, 1976 ?
40) Show faculty id, first name, last name but only for faculty id with number 11115
41) John has a yearly salary of 135000 dollars. Create that sentence with sql command
42) Sort customers name, address, phone in alphabetical order?
43) The customers table where the customer_id is between 4000 and 4999 ?
44) Select parts order from february 2, 2014 until february 28, 2014? From parts_order table?
45) Show employees that do not work for IBM, Oracle, AWS ?
46) Show all orders comming from state of Florida and food company is Hershey from order id that is less 1000
47) Remove duplicate from state, country from order table but total order must be higher then 50 and must be in state alphabetical order
48) Select all employees where commission_pct has null values?
49) Show all employees last name, where the first two characters is 'Sm' and the last two characters is 'th'.
50) Show all numbers which you know 6 numbers but you forgot the 7 digit:
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