Skip to Content
0
Former Member
Dec 05, 2005 at 11:02 AM

Plz Help its Urgent

30 Views

Hi All,

i want include Post Goods issue PGI in my output list and also find the latest date

in PGI,Installation,Contract signed,Action,Acceptence

Installation date VEDA – VINSDAT

Acceptance date VEDA – VABNDAT

Contract signed VEDA – VUNTDAT

Goods issue date LIKP - WADAT_IST

i will send the code plz send how to find latest and PGI

TABLES : VBAK,VBAP,VBEP,VEDA,LIPS,LIKP.

DATA: BEGIN OF T_VBMTV OCCURS 200,

BSTNK LIKE VBAK-BSTNK,

AUART LIKE VBAK-AUART,

KUNNR LIKE VBAK-KUNNR,

VBELN LIKE VBAK-KUNNR,

FAKSK LIKE VBAK-FAKSK,

POSNR LIKE VBAP-POSNR,

KWMENG LIKE VBAP-KWMENG,

VRKME LIKE VBAP-VRKME,

NETWR LIKE VBAP-NETWR,

WAERK LIKE VBAP-WAERK,

VASDA LIKE VEDA-VASDA,

VINSDAT LIKE VEDA-VINSDAT,

VABNDAT LIKE VEDA-VABNDAT,

VUNTDAT LIKE VEDA-VUNTDAT,

ETENR LIKE VBEP-ETENR,

EDATU LIKE VBEP-EDATU,

WADAT_IST LIKE LIKP-WADAT_IST,

LATEST_DATE TYPE D,

END OF T_VBMTV.

SELECT-OPTIONS S_VBELN FOR VBAK-VBELN.

SELECT-OPTIONS S_AUART FOR VBAK-AUART.

SELECT-OPTIONS S_KUNNR FOR VBAK-KUNNR.

SELECT-OPTIONS S_VABN FOR VEDA-VABNDAT.

SELECT VBAKBSTNK VBAKAUART VBAKKUNNR VBAKVBELN VBAK~FAKSK

VEDAVASDA VEDAVINSDAT VEDAVUNTDAT VEDAVABNDAT

VBAPPOSNR VBAPKWMENG VBAPVRKME VBAPNETWR VBAP~WAERK

VBEPETENR VBEPEDATU INTO CORRESPONDING FIELDS OF TABLE T_VBMTV

FROM ( ( ( VBAK INNER JOIN VEDA ON VEDAVBELN = VBAKVBELN )

INNER JOIN VBAP ON VBAKVBELN = VBAPVBELN )

INNER JOIN VBEP ON VBAKVBELN = VBEPVBELN

AND VBAPPOSNR = VBEPPOSNR )

WHERE VBAK~VBELN IN S_VBELN

AND VBAK~AUART IN S_AUART

AND VBAK~KUNNR IN S_KUNNR

AND VEDA~VABNDAT IN S_VABN.

PLZ REVIEW THE ABOVE CODE AND REPLY ME THE MODIFICATIONS

I WANT FIND THE LATEST DATE

HOW TO GET PGI FROM LIKP COMPARING THE ABOVE QUERY

ADVACED TAHNKS FOR UR REPLY

I LOOK FORWAR DTO UR REPLY

REGARDS

SEK