Wat is the difference between Select single * and Select ..
Up to one row . And which method is better for performance ?
Answers were Sorted based on User's Feedback
Answer / arjun manglekar
1)SELECT single retrives only one record which ever come
across first in data base query
SELECT ..upto 1 row , all records are fetched into a buffer
which are satisfied from Where condition in Data base
query , and from buffer first record is fetched .
>>same as Answer 2
2) If you know all the primary keys in WHERE condition ,
use SELECT single.
If you dont know all primary kyes in WHERE condition , use
SELECT UP TO...is gives better performace than select single
|Is This Answer Correct ?||11 Yes||1 No|
Answer / guest
Use Select single if all the primary keys are provided else
use select up to 1 rows as that would be faster.I agree
|Is This Answer Correct ?||8 Yes||0 No|
Answer / s.k.
Hi All ,
Actually in Select single * only one record is fetched
which ever come across first in data base query , but for
statment select ..upto 1 row , all records are fetched into
a buffer which are satisfied from Where condition in Data
base query , and from buffer first record is fetched .
So Select Single * is better for performance.
|Is This Answer Correct ?||9 Yes||4 No|
Answer / vijayaraghavan
Select Single * will pickup only one matching record from the database into the buffer, and returns the same to the internal table.
Select upto 1 rows will pickup all the records matching the condition into the buffer, but return the top record to the internal table.
|Is This Answer Correct ?||4 Yes||0 No|
Answer / vasu
i agree with aditya but if u know all primary key feilds in
that case only u go for select single *..other wise always
select up to n is the best..
|Is This Answer Correct ?||4 Yes||1 No|
Answer / aditya
select single read db records with primary key.
select upto doesnt read for a primary key, instead it will
try to find the most suitable index.
hence select upto is faster than select single.
|Is This Answer Correct ?||3 Yes||1 No|
Answer / stefan wagenblast
As looking on the performance analysis (ST05), both SELECTs
have the same estimated costs (I made a test). So because
estimated costs com from the database system, the same way
of searching in the table will be used --> no difference
which SELECT you use.
|Is This Answer Correct ?||1 Yes||1 No|
Answer / laxmi_nv
Select .. Up to one row will have better performance than
the Select single *
|Is This Answer Correct ?||5 Yes||9 No|
Answer / manoj kumar
select single * its complsary to use prmary key where as
selectup to one row there is no need of key and it will get
only one record where as in select single we will get
multiple record based on selection criteria
|Is This Answer Correct ?||0 Yes||12 No|
what are the control break statements in Reports?
what is the role of ST05 in performance tuning?
what will happen if you don't give occurs clause while creating an internal table?
Hi, How to do sub totals in classical reports?
What is a variable in the sap abap?
Give the syntax of Inner,outer Join?"
What do you mean by correction and Transportation system?
What is the function module for INDIAN PAYROLL to read table cluster for given cluster table and sequence number?
what is the differance b/w template and table in Smartforms?
Difference between jobpage and form page?
What is the difference between open sql & native sql ?
HI GUYS , FOR SAP INSTITUTION ATOS I BEST OR NOT? IAM PLANNING TO LEARN SAP COURSE IN ATOS... GIVE ME UR SUGGESTION ABOT ATOS?