← Back to team overview

c2c-oerpscenario team mailing list archive

Re: [Openerp-expert-accounting] [Bug 784339] [NEW] [stable 6.0.2] Account Balance Sheet parser logic error leads to incorrect totals amounts and developer confusion

 

Sorry Vinay this is not opinion it is bug.  I will release my improvements
to accounting community tomorrow, with new types and reports to support
equity, however I just look at the latest sources and all the bugs are all
still there.  Then I thought maybe you meant trunk - but it is exactly the
same??

If you need to ask accounting community opinion on whether a dr is on the
left or right side of a balance sheet then serious questions need asking.
Again if OpenERP genuinely believe that an asset can never have a negative
balance, more questions need asking.
If OpenERP really need to ask opinion if the left side of a balance sheet
total should equal the sum of the amounts above it - c'mon really?
Or whether a liability/equity account should ever be added or subtracted
from the Assets side?  This is the basics.

These were the bugs reported, I never asked you to change types, I just gave
an example from my own module on how we handle the negative balances.  It
was never suggested that OpenERP should add these types.  In fact
specifically it was written

"We use more types than standard but you get the idea.  Assets are their
balance, liability is their balance *-1."

On Thu, May 19, 2011 at 9:15 PM, Launchpad Bug Tracker <
784339@xxxxxxxxxxxxxxxxxx> wrote:

> You have been subscribed to a public bug by Vinay Rana (openerp)
> (vra-openerp):
>
> If you look at the section where it calculates sum_dr and sum_cr it is
> incorrect.  Well it is technically correct, but in the sense of having a
> balance sheet that balances it is incorrect.
>
> Take the accounting equation property = property rights expanded to
> assets = liabilities + equity
>
> In the case of a net profit we incorrectly add the result to sum_dr, our
> equity has increased afterall, so sum_cr should increase, (this
> behaviour is correct, except the function is named wrong) however in the
> case of a net loss we subtract the amount from sum_cr (which should be
> sum_dr) which is incorrect as our equity has reduced.
>
> However here is the first bug - sum_dr and sum_cr are around the wrong
> way - sum_cr is increased for asset accounts, and sum_dr is increased
> for liabilities - it should be the other way around
>
> Put another way, for a balance sheet, we don't really want the totals to
> be the sum of dr's and cr's, we want it to be the total of the stuff on
> the left (Assets) and the total of the stuff on the right (Property
> Rights).
>
> So in the case of a Net Profit we must increase equity (credit) and in
> the case of a net loss we must reduce equity (credit).  At no point
> should we be changing debits.  The value of our Assets has not changed
> (in so far that a net loss already reduces our assets), it is our equity
> that has reduced.
>
> Now to make this one step more confusing, and for some unknown reason it
> has been decided to leave liabilities as a negative balance, and then on
> the report use absolute value which is also incorrect.  Many assets and
> liabilities should have a balance opposite of the standard, Accumulated
> depreciation for example in Assets,  VAT Paid in Liabilities, Bank
> Accounts temporarily in overdraft.
>
> In my own parser, which I have written, to resolve this we declare a
> dictionary called signs and at the point we compute the account.balance
> we multiple it by the sign.
>
>        sign = {
>            'fixed_asset': 1,
>            'asset': 1,
>            'liability': -1,
>            'fixed_liability': -1,
>            'equity': -1,
>            }
>
> We use more types than standard but you get the idea.  Assets are their
> balance, liability is their balance *-1.
>
> Then all we do in the for account in accounts loop is make the balance:
> account.balance * sign[typ]
>
> So in summary
> sum_dr and sum_cr are round the wrong way.
> Adding a net loss to Assets is incorrect - it should be subtracted from
> Equity.
> values (already reported bug) should not be absolute, but rather their
> inverse for liability and equity accounts.
>
> ** Affects: openobject-addons
>     Importance: Undecided
>          Status: Opinion
>
> --
> [stable 6.0.2] Account Balance Sheet parser logic error leads to incorrect
> totals amounts and developer confusion
> https://bugs.launchpad.net/bugs/784339
> You received this bug notification because you are a member of OpenERP
> Accounting Experts, which is a direct subscriber.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~openerp-expert-accounting
> Post to     : openerp-expert-accounting@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~openerp-expert-accounting
> More help   : https://help.launchpad.net/ListHelp
>

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/784339

Title:
  [stable 6.0.2] Account Balance Sheet parser logic error leads to
  incorrect totals amounts and developer confusion

Status in OpenERP Modules (addons):
  Opinion

Bug description:
  If you look at the section where it calculates sum_dr and sum_cr it is
  incorrect.  Well it is technically correct, but in the sense of having
  a balance sheet that balances it is incorrect.

  Take the accounting equation property = property rights expanded to
  assets = liabilities + equity

  In the case of a net profit we incorrectly add the result to sum_dr,
  our equity has increased afterall, so sum_cr should increase, (this
  behaviour is correct, except the function is named wrong) however in
  the case of a net loss we subtract the amount from sum_cr (which
  should be sum_dr) which is incorrect as our equity has reduced.

  However here is the first bug - sum_dr and sum_cr are around the wrong
  way - sum_cr is increased for asset accounts, and sum_dr is increased
  for liabilities - it should be the other way around

  Put another way, for a balance sheet, we don't really want the totals
  to be the sum of dr's and cr's, we want it to be the total of the
  stuff on the left (Assets) and the total of the stuff on the right
  (Property Rights).

  So in the case of a Net Profit we must increase equity (credit) and in
  the case of a net loss we must reduce equity (credit).  At no point
  should we be changing debits.  The value of our Assets has not changed
  (in so far that a net loss already reduces our assets), it is our
  equity that has reduced.

  Now to make this one step more confusing, and for some unknown reason
  it has been decided to leave liabilities as a negative balance, and
  then on the report use absolute value which is also incorrect.  Many
  assets and liabilities should have a balance opposite of the standard,
  Accumulated depreciation for example in Assets,  VAT Paid in
  Liabilities, Bank Accounts temporarily in overdraft.

  In my own parser, which I have written, to resolve this we declare a
  dictionary called signs and at the point we compute the
  account.balance we multiple it by the sign.

          sign = {
              'fixed_asset': 1,
              'asset': 1,
              'liability': -1,
              'fixed_liability': -1,
              'equity': -1,
              }

  We use more types than standard but you get the idea.  Assets are
  their balance, liability is their balance *-1.

  Then all we do in the for account in accounts loop is make the
  balance: account.balance * sign[typ]

  So in summary
  sum_dr and sum_cr are round the wrong way.
  Adding a net loss to Assets is incorrect - it should be subtracted from Equity.
  values (already reported bug) should not be absolute, but rather their inverse for liability and equity accounts.


References