Skip to Content
0
Former Member
Jul 07, 2012 at 04:37 AM

ABAP select query fails intermittantly

555 Views

Hi ,

I am facing a strange issue with ABAP select query.

I am trying to retrieve a single field from the DB by firing a select query. The issue is a little bit strange in the sense the select returns with SY-SUBRC 4 at times and returns an empty field record.

The select fails 1 out of 10 times or so.

I tried and setup a breakpoint immediately after the select. When the select failed examined all the values used in the where condition of the select.Everything seems fine except the select fails to fetch the field. After reaching the breakpoint I re-executed the select by changing the program flow using go to statement to re-execute the failed select and this time it succeeds in the same run.

It appears that after Sufficient delay the select succeeds.The problem is the record is already commited to the DB.But when trying to read this particular field it fails at times.

The table I am trying to hit is BKPF.

Can the experts enlighten me as to why the select query may fail to retrieve any field.Any pointers in resolving/root causing this.

Thanks