Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

invoice date

Former Member
0 Likes
1,799

hi,

i want to get the invoice date.but i got the invoice number and invoice quantity from RSEG table.

the following is my coding.

DATA BKTXT(12).

SELECT * FROM ZGATEP INTO CORRESPONDING FIELDS OF TABLE ITAB2

WHERE ZDATE IN ZDATE

AND WERKS IN WERKS

AND GTEN IN GTEN.

LOOP AT ITAB2.

CLEAR BKTXT.

MOVE ITAB2-GTEN TO BKTXT.

SHIFT BKTXT LEFT DELETING LEADING '0'.

SELECT * FROM MKPF WHERE BKTXT = BKTXT.

  • AND BUDAT = ITAB1-DDATE.

IF SY-SUBRC EQ '0'.

SELECT * FROM MSEG WHERE WERKS IN WERKS

AND MBLNR = MKPF-MBLNR

AND MJAHR = MKPF-MJAHR

AND LIFNR = ITAB2-LIFNR

AND SHKZG = 'S'

AND BWART = '101'.

SELECT SINGLE * FROM RSEG WHERE EBELN = ITAB2-EBELN.

  • SELECT SINGLE BLDAT FROM BKPF INTO ITAB2-BLDAT WHERE

  • GJAHR = ITAB2-GJAHR.

IF SY-SUBRC EQ '0'.

MOVE MKPF-MBLNR TO ITAB2-MBLNR.

MOVE MKPF-MJAHR TO ITAB2-MJAHR.

MOVE MKPF-XBLNR TO ITAB2-XBLNR.

MOVE RSEG-BELNR TO ITAB2-BELNR.

MOVE RSEG-BPMNG TO ITAB2-BPMNG.

  • MOVE BKPF-BLDAT TO ITAB2-BLDAT.

ITAB2-BUKRS = MSEG-BUKRS.

ITAB2-WERKS = MSEG-WERKS.

ITAB2-BSTMG = MSEG-BSTMG.

ITAB2-MEINS = MSEG-MEINS.

ITAB2-EBELN = MSEG-EBELN.

MODIFY ITAB2.

MOVE-CORRESPONDING ITAB2 TO ITAB.

MOVE ITAB2-GTEN TO ITAB3-GTEN.

APPEND ITAB.

APPEND ITAB3.

CLEAR ITAB.

ENDIF.

ENDSELECT.

ENDIF.

  • ENDIF.

ENDSELECT.

  • ENDSELECT.

ENDLOOP.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,753

hi,

please b specific what u want exactly.

u want invoice date?

u wil get all invoicing data from vbrk, vbrp .........

19 REPLIES 19
Read only

Former Member
0 Likes
1,754

hi,

please b specific what u want exactly.

u want invoice date?

u wil get all invoicing data from vbrk, vbrp .........

Read only

0 Likes
1,753

i need invoice date based on the invoice document number that is from ME23N

Read only

0 Likes
1,753

in which tab invoice no. is coming? inme23n.

so that i wil help u?

Read only

0 Likes
1,753

in purchase order history tab

Read only

0 Likes
1,753

Table : RBKP.

field : BLDAT.

Read only

0 Likes
1,753

u r talking about reference no. indat tab.

if s then goto LIKP.

there pass that ref no. and get erdat.

U mean to say Delivery No. ?

coz LIKP = SD Document: Delivery Header Data

Read only

0 Likes
1,753

Hi Gautham,

Thank you.i got the output.

Read only

0 Likes
1,753

But you had assigned points to someone else.

Read only

0 Likes
1,753

i have assigned to you only.

Read only

0 Likes
1,753

.

Read only

0 Likes
1,753

You have the option to change it even after once you assign.

Plz check once again.

Read only

0 Likes
1,753

sorry by tension i have given the point to someone

Read only

0 Likes
1,753

u can change ur opinion again. dnt worry. means assigned him some other marks and 10 marks to correct answer

Read only

0 Likes
1,753

if u know,tell me the option.so that i can change

Read only

0 Likes
1,753

u can change the before answered option to very helpful or helpful option and make the Gautham reply Correct.

u can give 6 marks to two persons , 10 marks to only one and 2 marks to all. just click ont corresponding radio button.

Read only

0 Likes
1,753

if u know,tell me the option.so that i can change

Read only

0 Likes
1,753

This message was moderated.

Read only

Former Member
0 Likes
1,753

Hi

u will get the Date From MKPF table field is BUDAT

or also from MSEG .

regds

SACHHi

Read only

Former Member
0 Likes
1,753

Hi Sharmila,

U can get it from rbkp ....

Thanks

Karthik