I have a user requirement where I need to clear only a specific currency during payment lot posting or automatic clearing.
The client's system for the longest time transacts only using one currency, XXX, and is also the CCode currency. They have since introduced a contract account type that uses a second currency, YYY. As per business requirement and process, transactions and payments between these two currencies are segregated, i.e. CA's using XXX currency should only have XXX payments and debit items posted to them, likewise to CA's of YYY currency.
However, there are rare instances where user will incorrectly post an XXX payment to a YYY contract account. These are usually reversed later on and posted to the correct CA, but in the meantime, the effect is that when automatic clearing is executed or a YYY payment is posted to the account while the YYY payment is still open credit, the clearing document converts the cleared amount to XXX currency, which impacts other processes downstream since YYY currency is only expected for this CA type.
The projected solution, therefore, is to introduce a clearing variant step that is a copy of the clearing steps of XXX currency, but is specific only to the YYY currency along with its main and sub-transactions. The objective is that even if multiple currencies are selected from the CA during the clearing process, only YYY currency items are to be cleared, and no conversion should occur. Can anyone, therefore suggest what settings need to be applied, such as grouping characteristics, grouping rules, etc.? Thank you in advance.
in general, you should define a custom specific external grouping feature. In exit TFK116 (see template FKK_SAMPLE_TFK116) check CA and which currency is allowed and compare it with the currency of the item, then set T_e516_fkkcl-e_zreg_te516 = '3'. Use this grouping feature in your first clearing step of your clearing variant.