Code Monkey home page Code Monkey logo

Comments (4)

silky avatar silky commented on June 16, 2024 1

@simonmichael thanks; I see, hledger check accounts is what I want and I'm happy enough with that to close the issue.

To me it was just surprising to see the requirement for explicitness be part of strictness; but I get that it's probably best to just leave it as-is.

Thanks for the prompt response!

from hledger.

NobbZ avatar NobbZ commented on June 16, 2024

The 2 transactions are not equivalent.

The first one is unbalanced. When you add to one account, you have to deduct the other.

From my understanding the second os equivalent to this:

a   10 USD
b  -20 GBP

from hledger.

simonmichael avatar simonmichael commented on June 16, 2024

from hledger.

silky avatar silky commented on June 16, 2024

@NobbZ , sorry, I made a typo; I wanted a minus sign in there (i've edited the original post); but the idea is correct; consider the journal:

; a.journal
commodity 1,000.00 GBP
commodity 1,000.00 AUD

account a
account b

; Strict-checking fails
; 2021-01-01 Example
;   a  -10.00 AUD
;   b  20.00 GBP


; Strict-checking works
2021-01-01 Example
  a  -10.00 AUD @@ 20 GBP
  b

they both give the same balances (check with hledger -f a.journal reg) ; but the first one fails strict checking and the second does not.

from hledger.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.