2023 Aug 11 8:25 AM
Hi experts,
Have you ever faced this issue? do you know what is this and how to fix it?
2023 Aug 11 9:01 AM
2023 Aug 11 9:24 AM
.
2023 Aug 11 9:40 AM
There is no problem with SQL statements, you can also test them with fixed BLNER doc numbe
2023 Aug 11 9:45 AM
Thanks for your feedback.
This short-dump sometimes happens, not all the time, and when we rerun it is Ok. so I don't know why it happened
2023 Aug 11 9:16 AM
2023 Aug 11 9:28 AM
2023 Aug 11 10:38 AM
I don't know. It's their job, not mine as a developer.
The point is that this is most likely not a coding error, but an error with the database. Basis need to fix it.
2023 Aug 11 9:24 AM
Hi quyen,
the problem is with the BSEG table. This table is a cluster table and cannot be used in a JOIN. Perhaps that is the problem.
A possible solution:
You can do it for the table BSEG with the command FOR ALL ENTRIES instead of JOINS.
For example:
DATA: lt_bseg TYPE TABLE OF bseg.
SELECT * FROM bseg
INTO TABLE lt_bseg
FOR ALL ENTRIES IN @lt_openitems
WHERE belnr EQ @lt_openitems-doc_no
AND gjahr EQ @lt_openitems-fisc_year
AND bukrs EQ @lt_openitems-comp_code.
SELECT bkpf~bukrs,
bkpf~belnr,
...
FROM bkpf INNER JOIN acdoca ON acdoca~belnr EQ bkpf~belnr
..
LEFT OUTER JOIN vbpa ON bkpf~awkey EQ vbpa~vbeln
INTO TABLE @DATA(lt_ss02_data)
FOR ALL ENTRIES IN @lt_bseg
WHERE bkpf~belnr EQ @lt_bseg-belnr
...
Regards
Jim
2023 Aug 11 9:36 AM
Hi Turkaj,
Thanks for your answer.
but in my system( S4Hana) BSEG is Transparent table.
2023 Aug 11 10:39 AM
Joining a cluster table gives you a syntax error, not a dump.
2023 Aug 11 2:41 PM
Please post the code as text instead of image, so that one can easily answer by copying your code in order to complete it. Then, select your code and press the button [CODE], which makes the code appear colored/indented, it will be easier for people to look at it. Thank you!
Edit is possible via menu Actions > Edit.
Also, avoid posting just screenshots. For referencing your question:
SQL error 2: general error: key does not exist in the map
2023 Aug 11 2:45 PM
If you want to be assisted, don't share only the first lines of the short dump, attach it in full.
You can also search the error message in the Web and in the SAP notes.
For any database error as in your case (not ABAP), you should indicate which database you are using.