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 / pracheth
select * from temployees where to_char(hiredate,
'month') in
(to_char(trunc(sysdate,'month')-30,'month'),to_char(trunc(sysdate,'month')-60,'month'))
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What does rownum mean in sql?
How do temporal tables work?
Does oracle use sql?
What is embedded sql in db2?
what is a constraint? : Sql dba
What are types of joins?
What are inner outer left and right joins in sql?
what is the stuff function and how does it differ from the replace function? : Sql dba
how to convert character strings to numeric values? : Sql dba
Does sql full backup truncate logs?
Is sqlite free?
How do I start sql from command line?
What is database white box testing and black box testing?
what is a stored procedure? : Sql dba
Why is theta join required?