Hi,

I'm using the latest version of ledger from the git master branch.

I run the following command and get an error

$ ~/personal/workspaces/ledger/ledger -f ledger.dat bal
While parsing file "ledger.dat", line 37:
While balancing transaction from "ledger.dat", lines 35-37:
> 2010/01/22    Marketing B
>       Expenses:Marketing              55EUR {=$1.81818181818}
>       Liabilities:Accounts Payable    -$100
Unbalanced remainder is:
                 $10
Amount to balance against:
                $110
Error: Transaction does not balance

>From what I understand I should be using the rate 1.81818181818 to
convert the 55 euros into 100 dollars.

However this doesn't seem to be happening.

Here is the full ledger file

2009/01/01      Invoice A
        Assets:Accounts Payable         $1000
        Income:Sales

2009/01/21      Payment Invoice A
        Assets:NAB                      $1000
        Assets:Accounts Receivable

2009/01/22      Pay expenses
        Expenses:Payroll                $800
        Assets:NAB

2009/01/22      Marketing A
        Expenses:Marketing              50EUR {=$2}
        Liabilities:Accounts Payable    -$100

2009/01/23      Pay MC Marketing
        Assets:NAB                      -$100
        Liabilities:Accounts Payable

;-------------------------------------------------------

2010/01/01      Invoice B
        Assets:Accounts Payable         $1000
        Income:Sales

2010/01/21      Payment Invoice B
        Assets:NAB                      $1000
        Assets:Accounts Receivable

2010/01/22      Pay expenses
        Expenses:Payroll                $800
        Assets:NAB

2010/01/22      Marketing B
        Expenses:Marketing              55EUR {=$1.81818181818}
        Liabilities:Accounts Payable    -$101

2010/02/23      Pay MC Marketing
        Assets:NAB                      -$100
        Liabilities:Accounts Payable

Hope someone can explain to me what I'm doing wrong.

I also tried to use the fixed syntax

fixed EUR $1.81818181818
....
end fixed

but that always reported a parse error.

Pete

Reply via email to