Hello,
I have problem during checking below code. Error msg like on below screen. I have checked 'fixed point arithmetic' checkbox so I don't have any idea how to solve this issue. Thank you in advance for help.
Make sure that the variable SCANNED is of type I (integer). I guess that this message occurs when you use a variable of type P with number of decimals greater than zero (syntax error message "This Open SQL statement uses additions that can only be used when the fixed point arithmetic flag is activated (such as CASE expressions or host variables in ...")
unfortunately I have changed on Integer and it still doesn't work.
Then maybe the form is only valid for the strict SQL syntax, so you should the @ in front of variables ("host variables") i.e. use INTO @ SCANNED . Or do SELECT COUNT(*) INTO scanned FROM ... to use the non-strict syntax.
Thanks a lot. It works in this way:
So the solution is to change data type for Integer(I) and write code as follow.
Aff, I have antoher problem during group by... I was trying in many ways, with INTO @variable, @var... and with INTO at the end of select statement but it doesn't work. I would be appreciate if you have some tips. Thank you in advance.
I understand that the syntax is complex, and you should definitely read the ABAP documentation: SELECT. Look at the many examples, that will help you understand how "Open SQL" (the SQL in ABAP) works.
Using a comma for separating fields is allowed only in "strict syntax". The strict syntax means that the variables must be written as host variables (with leading @ ).
If the SELECT returns several lines then you must store the result into an internal table (INTO TABLE).