Posting Key determination
I have a query regarding how posting key is getting determined automatically.
Example : When raising one sales invoice along with discount to the customer, in that case A/c posting is happening as follows :
Customer A/c Dr
Discount A/c Dr
To Sales A/c Cr
How the above A/c posting (Dr / Cr ) is getting generated automatically? How it is understanding Customer and Discount are to l be debited and sales to be Credited ? I want to know the step by step configuration in IMG.