‎2007 Jul 03 1:14 PM
SAP Experts,
I am using a SELECT query on a database table. Since the number of records in the table is very large, <b>the program dumps due to insufficient memory</b>. How can I solve this?
‎2007 Jul 03 1:19 PM
Hi,
Use the Primary key field or use index fields or both in where condition and avoid the select * instead of all give field name according to the table field sequence
dont use into corresponding fields of
dont use table appending
Use INTO Internal table
or create seperate secondary index and use the index.
Try to give more where conditions without more validation < >= like this
Dont use Count / Min / Max functions in select query
use Joint
try to get primary key values from the header table fields and use it.
Regards,
nandha
Reward if it helps
‎2007 Jul 03 1:16 PM
Hi,
Can you paste your query?
There are no. of ways of tuning performance.
‎2007 Jul 03 1:16 PM
Hi vasanth,
Check this,
https://forums.sdn.sap.com/click.jspa?searchID=3615263&messageID=3442685
Thanks.
‎2007 Jul 03 1:17 PM
HI,
use the option <b>PACKAGE SIZE</b> to tell the packet size you want to use so that query fetches the data in packets of the size you mentioned.
Then process the each package in the SELECT ENDSELECT.
and clear you memory in the loop after the data is processed
Regards,
Sesh
‎2007 Jul 04 4:55 AM
‎2007 Jul 03 1:19 PM
Hi,
Use the Primary key field or use index fields or both in where condition and avoid the select * instead of all give field name according to the table field sequence
dont use into corresponding fields of
dont use table appending
Use INTO Internal table
or create seperate secondary index and use the index.
Try to give more where conditions without more validation < >= like this
Dont use Count / Min / Max functions in select query
use Joint
try to get primary key values from the header table fields and use it.
Regards,
nandha
Reward if it helps