Ansicht
Dokumentation

03780 - SQL 502: Cursor already open

03780 - SQL 502: Cursor already open

Fill RESBD Structure from EBP Component Structure   Vendor Master (General Section)  
This documentation is copyright by SAP AG.
SAP E-Book

SQL 502: Cursor already open

Hi Mike,

first of all, you are fortunately on the latest DBSL-level, as after there
was no change any more.

How to determine an SQL0502 problem?
It would be the easiest, if you could reproduce this problem in a dia_WP.
Then you could kill the first4 WPs hard on OS level in a more or less
"quite" time. The you go to SE38 and start the report RSTRC000. Here you can
mark an "X" at "hold WP". When you then have a look in SM50 from another WP
you see it "locked". This means that you now occupy a WP (similar to
debugging, but more strange). Now you do a STRSRVJOB on OS-level against
this WP and issue then STRDBG UPDPROD(*YES). You change the job to *PRTWRAP,
so that all wrapped joblog-data becomes dumped to spool. It is necessary to
kill the WP before, because you should have as few ODPs opena possible,
because otherwise you perhaps won't see the cursor-names that cause SQL0502
twice in the joblog.
When you now issue in this WP your report, you will encounter the problem
and can search for this cursor if it was already opened before. Then you
should have a look to these entries if a commit is in between to the error
and if at least the new cursoris a "with hold" cursor or not. You can check
this in the dev-trace. Unfortunately we can't check this at the moment for
the old cursor.

I think your problem only occured when 3-tier, then you have to use the
DB-shadow-job with STRDBG and STRSRVJOB. You can find out the name and
number in the dev-trace.

My DBSL-collegue thinks about changing the cursor-naming-conventions, so
that we can see if this is a "with hold" cursor or not. Then the analysis
would become a lot easier.

When you opened an OSS ticket, let me know, I will take this over then.

Regards

Volker

Durban Tours - Südafrika Safari

ABAP Short Reference   SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up  
This documentation is copyright by SAP AG.

Length: 2233 Date: 20240426 Time: 133317     sap01-206 ( 2 ms )