Hello, this is for Oracle SQL. Table: Employees Employee First_Name Last Name De
ID: 3874166 • Letter: H
Question
Hello, this is for Oracle SQL.
Table: Employees Employee First_Name Last Name Dept Code Credit Limit Phone Manager_id Ext Hire_Date 201 202 203 204 205 206 207 208 209 210 Brown Kern Woods Owens Perkins Rose Smith Campbel1 Jacobs Hoffman 01-Jun-1998 16-Aug-1999 02-Feb-2004 01-Jul-2003 01-Mar-2000 nu1l 01-Dec-2004 01-Apr-2003 17-Mar-1999 16-Feb-2004 $30.00 $25.00 $25.00 $15.00 $25.00 null $25.00 $30.00 $15.00 $25.00 3484(nul1) 8722 7591 6830 5286 null (nul1) 2259 1752 3357 2974 Susan Exe Sa l 201 201 202 202 1 m Martha Ellen Hen Caro Dan Fred Paula Nancy Sa Sa l Act 203 203 201 203 Mkt Task#5: List all the employees, their hire dates and the number of days each person will have worked for the company as of January 1, 2005.Explanation / Answer
Please run below query to get to see the results:
select first_name, last_name, hire_date,
to_date('2005-01-01', 'yyyy-mm-dd') - trunc(hire_date)
from Employees;
to_date creates a date from a format and subtracting the other date results in number of days between the dates.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.