Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Performance

Former Member
0 Kudos

Which one is better performance wise?

Select single * or Read with Binary Search?

Which one will take lesser time?

What are the reasons for that?

Thanks,

Archana.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

SAP work's on 3 tier arch.

Read take's lesser time than select single why because read statement happens n application layer whereas select single will go to the DB table to fetch data here where condition is important based on which indexes will be used , so if the where cluase contains fields other than key and indexes fields it would take much longer time to fetch.

Note : before doing read binary search sort the itab.

Edited by: karthik arunachalam on Sep 3, 2008 12:00 AM

7 REPLIES 7

Former Member
0 Kudos

SAP work's on 3 tier arch.

Read take's lesser time than select single why because read statement happens n application layer whereas select single will go to the DB table to fetch data here where condition is important based on which indexes will be used , so if the where cluase contains fields other than key and indexes fields it would take much longer time to fetch.

Note : before doing read binary search sort the itab.

Edited by: karthik arunachalam on Sep 3, 2008 12:00 AM

0 Kudos

Karthik, thank you for the reply.

We would do a Select before read as well right ?

So wont the select into table and read time and Select single * time be same?

Thanks,

Archana.

0 Kudos

Hi,

Did you try the SE30 (Tips and Tricks button)?

You can code two diferent codes and compare time.

0 Kudos

read with binary search is only necessary if you have a lot of records in you're internal table (>10.000 for instance)

otherwise you won't notice.

kind regards

arthur de smidt

Former Member
0 Kudos

Mmmmm.... Select single hits the database now and then, the connectivity between the database and application layer will cost more time. In lay man terms Its like this you have a rack full of books you pull all the necessary books once and use it for reference thatu2019s one type and the other is when ever you need to refer a book you go to the rack and pick it up and refer the time taken for you to reach the rack will consume time rite!!!

Hope you are clear with the above explanation.

Former Member
0 Kudos

Obviously "Read Statement" after sorted is good.

Still this question is unanswered. How pity?

JozsefSzikszai
Active Contributor
0 Kudos

>

> Which one is better performance wise?

> Select single * or Read with Binary Search?

it does not make much sense to compare these two statements, because they are used for different purposes! They are not replacing each other!