You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thank you for reporting this! Unfortunately, I can't reproduce this error yet, maybe because it depends on a certain rule configuration. Could you please attach the profile with which this error comes up? (menu "Help / Open Profiles Folder…", then attach .cfj file with the profile name).
Can you tell me if it is me or the ABAP Cleaner?
It's definitely ABAP cleaner: If the syntax is correct, ABAP cleaner should be able to deal with it! (Well, apart from a few exceptions like macros with incomplete code blocks, or chain colons inside parentheses, but those provoke specific "unsupported" messages).
hm, unfortunately, I still can't reproduce the issue, even with the profile. You are using the current release 1.13.1 (menu "Help / About"), right? Does the error log (menu "Help / Open Error Log") contain any more details?
Maybe this issue depends on the context, too. In that case, unfortunately, I'd have to ask for some more work on your end… Could you please:
copy the complete code from the ADT editor to any text editor (e.g. Notepad++)
in ADT, open menu "Source Code / Show Read-Only Preview With ABAP Cleaner …"
you can now use Ctrl+C / Ctrl+V to paste code from the text editor to ABAP cleaner multiple times, trying to reduce the code to a minimum example that triggers the error
I am happy if I can help. I shrunk everything down as far as I could and the error is still there.
REPORT. DATA gt_auftrag TYPE STANDARD TABLE OF resb. PARAMETERS s_werks TYPE werks_d OBLIGATORY. START-OF-SELECTION. MODULE status_0100 OUTPUT. LOOP AT gt_auftrag ASSIGNING FIELD-SYMBOL(<ls_auftrag>). SELECT aufnr, lead_aufnr, objnr, plnbez, stlbez FROM caufv INTO ( @DATA(lv_aufnr), @DATA(lv_lead), @DATA(lv_objnr), @<ls_auftrag>-matnr, @DATA(lv_stlbez) ) WHERE aufnr = @<ls_auftrag>-aufnr AND werks = @s_werks AND loekz = @space. ENDSELECT. ENDLOOP. ENDMODULE.
I have tried it outside the MODULE. It works there, so that could be the reason. Is MODULE not supported?
oh, this is too bad! It's the "Align SELECT lists" rule, which tries to keep the maximum line length of 100. So, an even shorter example (no context needed) would be:
SELECT f1, f2, f3
FROM any_dtab
INTO ( @DATA(lv_var_1_with_long_name), @DATA(lv_var_2_with_very_long_name), @DATA(lv_var_3_with_long_name) ).
ENDSELECT.
which is changed to
SELECT f1, f2, f3
FROM any_dtab
INTO ( @DATA(lv_var_1_with_long_name), @DATA(lv_var_2_with_very_long_name), @DATA(
lv_var_3_with_long_name) ).
ENDSELECT.
sorry, i dont get it yet. I've changed the MODULE to an IF-clause. The Error is still there. I understand that it is also because he has to indent in so far. In your example, I don't understand why ABAP Cleaner indents the third varible like this. If I separate the variable from the DATA in my code, I can no longer activate the programme and I get an error.
The line length from the profile is counted from the beginning of the line, isn't it?
For me to understand, is the behaviour so desired and would I need to adjust my profile or are you doing some "magic" ;)?
sorry for the confusion: My example was just demonstrating the bug: ABAP cleaner tries to limit the line length to 100 in the INTO clause (as configured in the profile), but it introduces a syntax error by breaking the line after @DATA(, rather than keeping the inline declaration together. So that is the bug which I'll have to fix, since of course, @DATA( must not be detached from the variable name.
thanks again for reporting this and for your help in narrowing down the issue! This bug should now be resolved with version 1.13.2, which was just released.
Activity
JoachimEck commentedon Feb 19, 2024
Hey,

if I swap the variables, it works:
Can you please check why it doesn't work in the other way.
Thanks,
Joachim
jmgrassau commentedon Feb 19, 2024
Hi Joachim,
thank you for reporting this! Unfortunately, I can't reproduce this error yet, maybe because it depends on a certain rule configuration. Could you please attach the profile with which this error comes up? (menu "Help / Open Profiles Folder…", then attach .cfj file with the profile name).
It's definitely ABAP cleaner: If the syntax is correct, ABAP cleaner should be able to deal with it! (Well, apart from a few exceptions like macros with incomplete code blocks, or chain colons inside parentheses, but those provoke specific "unsupported" messages).
Kind regards,
Jörg-Michael
JoachimEck commentedon Feb 19, 2024
Hey Jörg-Michael,
thanks for the quick reply.
Here is my profile, which I use:
profile.zip
Kind regards,
Joachim
jmgrassau commentedon Feb 19, 2024
Hi Joachim,
hm, unfortunately, I still can't reproduce the issue, even with the profile. You are using the current release 1.13.1 (menu "Help / About"), right? Does the error log (menu "Help / Open Error Log") contain any more details?
Maybe this issue depends on the context, too. In that case, unfortunately, I'd have to ask for some more work on your end… Could you please:
Kind regards,
Jörg-Michael
JoachimEck commentedon Feb 19, 2024
Hi Jörg-Michael,
I am happy if I can help. I shrunk everything down as far as I could and the error is still there.

REPORT. DATA gt_auftrag TYPE STANDARD TABLE OF resb. PARAMETERS s_werks TYPE werks_d OBLIGATORY. START-OF-SELECTION. MODULE status_0100 OUTPUT. LOOP AT gt_auftrag ASSIGNING FIELD-SYMBOL(<ls_auftrag>). SELECT aufnr, lead_aufnr, objnr, plnbez, stlbez FROM caufv INTO ( @DATA(lv_aufnr), @DATA(lv_lead), @DATA(lv_objnr), @<ls_auftrag>-matnr, @DATA(lv_stlbez) ) WHERE aufnr = @<ls_auftrag>-aufnr AND werks = @s_werks AND loekz = @space. ENDSELECT. ENDLOOP. ENDMODULE.I have tried it outside the MODULE. It works there, so that could be the reason. Is MODULE not supported?
Kind regards,
Joachim
jmgrassau commentedon Feb 19, 2024
Hi Joachim,
ah, great, now I get the error message, too! Thanks for your help, let's see what causes this issue!
Kind regards,
Jörg-Michael
jmgrassau commentedon Feb 19, 2024
Hi Joachim,
oh, this is too bad! It's the "Align SELECT lists" rule, which tries to keep the maximum line length of 100. So, an even shorter example (no context needed) would be:
which is changed to
Kind regards,
Jörg-Michael
JoachimEck commentedon Feb 19, 2024
Hi Jörg-Michael,
sorry, i dont get it yet. I've changed the MODULE to an IF-clause. The Error is still there. I understand that it is also because he has to indent in so far. In your example, I don't understand why ABAP Cleaner indents the third varible like this. If I separate the variable from the DATA in my code, I can no longer activate the programme and I get an error.
The line length from the profile is counted from the beginning of the line, isn't it?
For me to understand, is the behaviour so desired and would I need to adjust my profile or are you doing some "magic" ;)?
Kind regards
Joachim
jmgrassau commentedon Feb 19, 2024
Hi Joachim,
sorry for the confusion: My example was just demonstrating the bug: ABAP cleaner tries to limit the line length to 100 in the INTO clause (as configured in the profile), but it introduces a syntax error by breaking the line after
@DATA(, rather than keeping the inline declaration together. So that is the bug which I'll have to fix, since of course,@DATA(must not be detached from the variable name.Kind regards,
Jörg-Michael
JoachimEck commentedon Feb 19, 2024
Hi Jörg-Michael,
got it! Thanks!
Kind regards,
Joachim
jmgrassau commentedon Feb 19, 2024
Hi Joachim,
this will be fixed with the next release, so "Align SELECT lists" then keeps the inline declaration together:
Kind regards,
Jörg-Michael
JoachimEck commentedon Feb 19, 2024
Hi Jörg-Michael,
that was quick!
Thanks.
Kind regards,
Joachim
fix AlignSelectListsRule for line breaks with inline declarations (SA…
fix AlignSelectListsRule for line breaks with inline declarations (#251)
jmgrassau commentedon Feb 27, 2024
Hi Joachim,
thanks again for reporting this and for your help in narrowing down the issue! This bug should now be resolved with version 1.13.2, which was just released.
Kind regards,
Jörg-Michael