suppose I have two table one Emp and other is dpt.
Emp table has a field ,dept id,name ,sal and dpt table has a
field dept id,dept name.
Now I want to find out the emplyee list whose sal is between
2000-3000 from dept x.
Answer Posted / abhishekjaiswal
select e.department_id,e.last_name,e.salary,d.department_name from employees e,
departments d
where e.department_id=d.department_id and
e.salary between 2000 and 10000
and lower(d.department_name)='finance'
/
Out put
DEPARTMENT_ID LAST_NAME SALARY DEPARTMENT_NAME
------------- ------------------------- ---------- --------------------
100 Faviet 9000 Finance
100 Chen 8200 Finance
100 Sciarra 7700 Finance
100 Urman 7800 Finance
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Hi am new to PLSQL & facing problems in writing code like in SP, Functions, so any one having some SP coding with in depth explanation please share with me my Email ID suvarnaatsuvarna@rediffmail.com Or taking tanning on this please do contact me
how to use regular expression in pattern match conditions? : Sql dba
Is inner join faster than left join?
What is the current version of sql?
what is schema? : Sql dba
What is the best sql course?
how to escape special characters in sql statements? : Sql dba
Is primary key clustered index?
If a cursor is open, how can we find in a pl/sql block?
how to start mysql server? : Sql dba
How do I remove duplicates in two columns?
Does group by remove duplicates?
Can delete statement be rollbacked?
what is dbms? : Sql dba
what is collation? : Sql dba