Urgent! I am going mad!
Hi.
i have a very serious problem which might be solved easily. but i don't know how!!! i have tried for several hours, but it doesn`t work.
the question:
can i change the where condition of a graphically created join in the infoset?
here's the join:
SELECT IFLOT~TPLNR ILOA~ILOAN ILOA~KOSTL ILOA~TPLNR QMIH~AUSBS
QMIH~AUSVN QMIH~AUSZT QMIH~AUZTB QMIH~AUZTV QMIH~ILOAN
QMIH~QMNUM QMMA~MATXT QMMA~QMNUM QMEL~OBJNR QMEL~QMNUM
JEST~OBJNR
INTO (IFLOT-TPLNR , ILOA-ILOAN , ILOA-KOSTL , ILOA-TPLNR , QMIH-AUSBS
, QMIH-AUSVN , QMIH-AUSZT , QMIH-AUZTB , QMIH-AUZTV , QMIH-ILOAN
, QMIH-QMNUM , QMMA-MATXT , QMMA-QMNUM , QMEL-OBJNR , QMEL-QMNUM
, JEST-OBJNR )
FROM ( IFLOT
INNER JOIN ILOA
ON ILOA~TPLNR = IFLOT~TPLNR
INNER JOIN QMIH
ON QMIH~ILOAN = ILOA~ILOAN
INNER JOIN QMMA
ON QMMA~QMNUM = QMIH~QMNUM
INNER JOIN QMEL
ON QMEL~QMNUM = QMIH~QMNUM
INNER JOIN JEST
ON JEST~OBJNR = QMEL~OBJNR )
WHERE IFLOT~TPLNR IN SP$00001.
i want to add:
...where iflot~tplnr in SP$00001
and jest~stat = 'I0072'
and jest~inact <> 'X'.
Is this possible?
the person who can solve the problem should be crowned
greetings from bavaria,
donald
Have you tried specifying jest~stat and jest~inact as selection fields. The query will then automatically take them into account. In the selection screen you could then specify your required values for those two fields ('I0072' and 'X'). It should work.
Regards
Dave
The following ABAP code is syntactically correct ...
*
ranges: r_tplnr for iflot-tplnr.
tables: iflot,
iloa, qmih, qmel, qmma, jest.
SELECT IFLOT~TPLNR ILOA~ILOAN ILOA~KOSTL ILOA~TPLNR QMIH~AUSBS
QMIH~AUSVN QMIH~AUSZT QMIH~AUZTB QMIH~AUZTV QMIH~ILOAN
QMIH~QMNUM QMMA~MATXT QMMA~QMNUM QMEL~OBJNR QMEL~QMNUM
JEST~OBJNR
INTO (IFLOT-TPLNR , ILOA-ILOAN , ILOA-KOSTL , ILOA-TPLNR , QMIH-AUSBS
, QMIH-AUSVN , QMIH-AUSZT , QMIH-AUZTB , QMIH-AUZTV , QMIH-ILOAN
, QMIH-QMNUM , QMMA-MATXT , QMMA-QMNUM , QMEL-OBJNR , QMEL-QMNUM
, JEST-OBJNR )
FROM ( IFLOT
INNER JOIN ILOA
ON ILOA~TPLNR = IFLOT~TPLNR
INNER JOIN QMIH
ON QMIH~ILOAN = ILOA~ILOAN
INNER JOIN QMMA
ON QMMA~QMNUM = QMIH~QMNUM
INNER JOIN QMEL
ON QMEL~QMNUM = QMIH~QMNUM
INNER JOIN JEST
ON JEST~OBJNR = QMEL~OBJNR )
WHERE ( IFLOT~TPLNR IN r_tplnr
and jest~stat = 'I0072'
and jest~inact <> 'X' ).
endselect.
---------------------------------------------
I did not test the execution ... that is left for you!
Hope this helps,
_________________
Duane