cancel
Showing results for 
Search instead for 
Did you mean: 

PMW DMEE Change Payment Output file name

fpinkney
Explorer
0 Kudos

2 Part question pertaining to changing PMW DMEE output file name to include our specific "FILETYPE"

1. How do I change the filename dynamically and... (I've been reading about event 21)

2. If the resolution is to use event 21, can I access any fields in the tree to pass file type to event 21?

DMEEX Tree is used is configured to a specific Payment Method

During the setup for F110 Payment Run users enter info in the Free Selection tab to narrow down further the TYPE of open items. There are 3 different TYPES.

I use an EXIT to determine the FILE TYPE in the mapping and outputting it in the 2nd line of my formatted file. Basic logic is to look at one of the Vendors and check their Acct Group with a CASE statement.

CASE I_EXTENSION-NODE-NODE_ID.
WHEN 'N_2260445360' or 'N_3155287310'.
SELECT SINGLE KTOKK
From lfa1 INTO V_ACCT_GRP
WHERE LIFNR = <I_ITEM>-FPAYH-GPA1R." VENDOR NUMBER
IF V_ACCT_GRP = 'Z006'.
C_VALUE = 'TRAVEL'.
ELSEIF V_ACCT_GRP = 'Z004'.
C_VALUE = 'FOREIGN'.
ELSE.
C_VALUE = 'VENDOR'.
ENDIF.

Accepted Solutions (1)

Accepted Solutions (1)

MarekTurczynski
Contributor
0 Kudos

Hi fnp

you can use event 21 to influence the file name. Please copy the sample FM: FI_PAYMEDIUM_SAMPLE_21 to your own one and do the adjustments there.


You have structures FPAYH and FPAYHX as well as the format parameters available in that FM.


Please do never use I_EXTENSION-NODE-NODE_ID becasue it can change! If is enough that someone deletes the node, creates it again with same name but system will give it another ID!


To meet your requirement you can use the FPAYH structure to obtain the account group of vendors. Please also see that you need to make sure that there is only 1 account group used in the payment run to ascertain that your determination works correct.

If I were you I would rather base it on payment method which can also indicate it this is Foreign or Domestic / Travel transfer.

Please also always remember to concatenate parameter 'i_filename' with your value - by this you will overtake the part entered in the variant and just add your extension to it.

Regards,

Marek Turczyński

fpinkney
Explorer
0 Kudos

Thanks Marek,

I agree, different payment methods would be easier, unfortunately that decision was out of my hands. I will take you advice on programming event 21 utilizing the same logic to determine TYPE.

Warm regards,

Felilce

Answers (0)