Computer Science, asked by sakthivel192, 9 months ago

Create a query to display the last name and the number of weeks employed for all employees in department 90. Label the number of weeks column as tenure. Truncate the number of weeks value to 0 decimal places. Show the records in descending order of the employee's tenure. Note: the tenure value will differ as it depends on the date on which you run the query.

Answers

Answered by charlie1505
5

Answer:

create table for employees-

create table emp_ten(firstname varchar[10],lastname varchar[20],tenure int);

display table-

select lastname, tenure from emp_ten;

truncate-

update emp_ten set tenure=null;

Display records in descending order-

SELECT * FROM emp_ten ORDER BY tenure DESC;

Similar questions