أريد إختيار عدد معين فقط من جدول يحقق شروط
وليكن 20 من 100 موظف يحققون جميعا شروط الجملة
أريد إختيار عدد معين فقط من جدول يحقق شروط
وليكن 20 من 100 موظف يحققون جميعا شروط الجملة
select * from Emp Where Emp.Emp_name where emp.emp_name="ali"
استرجاع جميع اسماء الموظفين الذين اسماؤهم علي
تم تعديل هذه المشاركة بواسطة System.Error في 17 يناير 2007 في 10:27
_.-SysteM.ErroR-._
select * from Emp Where Emp.Emp_name where emp.emp_name="ali"
استرجاع جميع اسماء الموظفين الذين اسماؤهم علي
تم تعديل هذه المشاركة بواسطة System.Error في 17 يناير 2007 في 10:26
_.-SysteM.ErroR-._
يوجد ملخص ل sql مكتوب بقلم الاخ jamal_rrkk يمكنك الاستفاده منه اكتر
;) ;)
-waf
تم تعديل هذه المشاركة بواسطة System.Error في 17 يناير 2007 في 10:26
_.-SysteM.ErroR-._
السلام عليكم
if u want 20 employees randomly u can use then :
select * from employees
where condition1
and condition2 ...etc
and rownum<=20
if u want to order the result first then choose the first 20 record u can use:
select * from (select * from employees order by last_name) where condition1
and condition2 ...etc
and rownum<=20
i hope that what i write is helpful to u
bye
try the following
select top <n> from <tablename> where <condition>
for example
select top 50 from employees where emp_name like '%Ali %'
هذا الموضوع مغلق.