الانتقال إلى المحتوى

ساعدووووووووووني :(


ad-20-ad

Recommended Posts

1- write a query to display the employee name and hiredate for all employees in the same department as Blake.Exclude Blake.

2- Create a query to display the employee number and name for employees who earn more than the average salary.Sort the results in descending order of salary.

3- write a query that will display the employee number and name for all employees who work in a department with any employee whose name contains a T.

4- display the employee name,department number,and job title for all employees whose department location is Dallas.

5- display the employee name and salary of all employees who report tp King.

6- display the department number,name,and job for all employees in the Sales department.

:) :) :blink: :( :(

رابط هذا التعليق
شارك

السلام عليكم

السؤال الأول

select empname,hiredate 
from emp
where dept_id=(select dept_id from emp where  initcap(empname) like 'Blake')
and empname not like  intcap(empname)



السؤال الثانى

select emp_id,enpname
from emp
where salary >(select avg(salary) from emp)
order by salary desc



السؤال الثالث

select emp_id,enpname
from emp
where upper(empname) like'%T%'


وسوف اكتب لك باقى الاجابات ان شاء الله وارجو من الأخوة الاعضاء التعليق على الاجابات والمراجع لتعم الفائدة

تم تعديل بواسطة m_ahmed
رابط هذا التعليق
شارك

اتفضل اخوي

4- display the employee name,department number,and job title for all employees whose department location is Dallas


select   Empname, depno,job_title
 from employee, department
where deptlocation=dallas



display the employee name and salary of all employees who report tp King- 5

select   empname, salary
from employee,salary where report tp=king



display the department number,name,and job for all employees in the Sales department- 6

select  DEPTNO, ENAME, EJOB
FROM DEPARTMENT, EMPLOYEE
WHERE DEPTNO=SALES



تمنى تكون صحيحة لأني مبتدئة و اذا فيها خطأ ياريت التصحيح :)

رابط هذا التعليق
شارك

انضم إلى المناقشة

يمكنك المشاركة الآن والتسجيل لاحقاً. إذا كان لديك حساب, سجل دخولك الآن لتقوم بالمشاركة من خلال حسابك.

زائر
أضف رد على هذا الموضوع...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   تمت استعادة المحتوى السابق الخاص بك.   مسح المحرر

×   You cannot paste images directly. Upload or insert images from URL.

جاري التحميل
×
×
  • أضف...

برجاء الإنتباه

بإستخدامك للموقع فأنت تتعهد بالموافقة على هذه البنود: سياسة الخصوصية