-
Notifications
You must be signed in to change notification settings - Fork 53
No Corresponding FORM - If "SELECT UP TO 1 ROWS" is inside the FORM #159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi JoachimEck, this sound a bit like ABAP cleaner (wrongly) expects an ENDSELECT and therefore doesn't expect the FORM block to be closed yet when the ENDFORM is parsed. Unfortunately, it is not trivial to determine whether or not ENDSELECT is required – could you post the SELECT statement used here? (Exact table and field names don't matter, but the structure of the SELECT). Kind regards, |
Hi Jörg-Michael,
I have not been an ABAP developer for very long. I would have said that only one value comes back with the SELECT, so I could leave out the addition, but I have read that it can apparently also be that several values come back. The report is already old and I don't want to change the logic. Kind regards, |
Hi Joachim, ah, very good, now I could reproduce the issue. What confuses ABAP cleaner here is that "UP TO 1 ROWS" is in an unusual position – you'd usually have it after the "INTO" clause (see ABAP documentation for SELECT):
But nevertheless, since the ABAP compiler accepts the syntax from your example, ABAP cleaner should cope with it, too, so I shall try to fix this! In the meantime, if you move "UP TO 1 ROWS" below "INTO variable", ABAP cleaner should be fine with it, too. Kind regards, |
Thanks a lot :) Kind regards, |
Hi Joachim, this issue will be fixed in the next release! Kind regards, |
Hi Joachim, thanks again for this finding – this should now be fixed in version 1.8.0, which was just released! Kind regards, |
Hello,

I don't know if this is a issue, but I have an old report in which a SELECT is executed with the addition "UP TO 1 ROWS". This happens inside a FORM. When I want to run the ABAP CLeaner, I get the following error message:
If I comment out the addition "UP TO 1 ROWS", it works again.
The text was updated successfully, but these errors were encountered: