Errors when using large range table
One of the most convenient features of SAP SQL statements is the IN operator. Using IN, the programmer can dynamically build a WHERE clause with a great deal of flexibility. It is important to understand what happens when you use IN to avoid database errors.
After a SELECT statement is executed, all records in the range table are added to the WHERE clause. This works well when the range table is small (less than 1,000 records) but as the size of the range table increases, the length of the WHERE clause increases until the length exceeds the maximum size that can be passed to the database. You can identify this error when the ABAP program terminates with a short dump that contains the error BIF_RSQL_INVALID_REQUEST.
This was first published in April 2004
Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.