‎2007 Feb 08 8:48 AM
hi,
can you provide the alernative to
select single * to increase the performance
‎2007 Feb 08 8:52 AM
Hi,
If you want to get the best performance with SELECT SINGLE only way out is to have all the fields of the primary key in the WHERE clause.
Regards,
Sesh
‎2007 Feb 08 8:55 AM
Hi Shyam,
Most of performance problem are du to the way ( the table chain) to retrieve the data, not the statement you use.
The "select single" statement is performant. But do you fill all the table key in your "where clause" ?
‎2007 Feb 08 9:00 AM
Hi,
Don't use Select Single *, but try specify your field.
SELECT SINGLE Field1 Field2 FieldN ...
FROM TableName
INTO (Field1, Field2, FieldN, ... )
WHERE (your where condition here ).
Regards,
‎2007 Feb 08 11:59 AM
Hi,
a select single with (primary) index access will be faster - and there is no faster way. But when you don't have index access, no other select will be faster, too.
Only when you make the select single inside a loop, the thousands of repetitions will summarize to some time. Here a select for all entries outside of the loop should be faster.
‎2007 Feb 09 10:23 AM
select single is a good performance clause ... but try specifying the fields you want to retiree plus in the where clause try to specify all the primary fields in the table this will improve the performance considerably .an exact alternative is using upto 1 rows but select single in better than upto one rows.
pl .provide point if found helpful.
‎2007 Feb 09 2:31 PM
hi
u have to use the select single only if u have full primary key..otherwise u will not get the expected resuet.. suppose
select single * from vbap
into wa_vbap
where vbeln = xxxx and
posnr = xxxx.if u dont have the POSNR value the use upto 1 rows..
select * from
vbap into wa_vbap
up to 1 rows
where vbeln = xxxx
end select.