I want to display the employees who have joined in last two
months. (It should be executed randomly means If I execute
the query in March it should display Jan and Feb joined
employees. Same query if i execute in Feb, 2007 it should
display dec, 2006 and jan 2007 joined employees.

Answer Posted / venkat

select *from emp where floor(months_between
(sysdate,hiredate))=2;

Is This Answer Correct ?    6 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how to enter numeric values as hex numbers? : Sql dba

559


What is java sql drivermanager?

534


What is difference between stored procedures and application procedures?

555


how can we submit a form without a submit button? : Sql dba

524


What are schema-level triggers?

566






what is rdbms? : Sql dba

566


What is difference between hql and sql?

489


what is the syntax for using sql_variant_property? : Transact sql

520


What is the use of desc in sql?

479


What is a subquery in sql?

493


list out some tools through which we can draw e-r diagrams for mysql. : Sql dba

495


What is use of package in pl sql?

520


What is a natural join?

500


Define the select into statement.

557


Can we commit inside a trigger?

537