Thanks Gustavo, let me put into another context or example. But first of all let me clarify: The example below is referring to recording a transaction in accounting software. When you record something, it will be debited or credited to a ledger.
So, for example:
When you purchase something for business purposes, the amount you incurred should be recorded against/to "X" ledger, instead of "Y" ledger.