‎2007 Jan 04 6:25 AM
I am making a query using sq02.
Select Single * from TSP02
where PJFINAHERR = 1.
<b>IF SY-SUBRC = 0.
myvariable = PJIDENT. 'Primary Key
ENDIF.
</b>
thats the short code.
but after testing the query it outputs multiple but same data.
it outputs:
13229
13229
13229
13229
13229
13229
13229
13229
13229
13229
and so on and so forth.
could you pls. advise?
Thank you in advance.
‎2007 Jan 04 6:31 AM
see demo code -
tables tsp02.
data myvariable like tsp02-pjident.
Select Single * from TSP02
where PJFINAHERR = 1.
IF SY-SUBRC = 0.
myvariable = tsp02-PJIDENT.
ENDIF.
write: myvariable.