Re: [GNC] [Bug 798864] Budget Revalues for the Income are positive numbers.porting on select reports are wrong

2023-04-17 Thread Michael or Penny Novack

On 4/17/2023 4:01 AM, Richard Lindgren wrote:

Sounds like you understand my problem. However, since I'm not a programmer, I 
hesitate to tackle this patch. Maybe it is easier than it looks and is probably 
the best fix? I'm just nervous here.

Let me ask this basic question. When I am creating my Budget, I have assumed 
this:
 1. All Income values are positive numbers.
 2. All Expense values are negative numbers.

With that being said and used, my reports work for; a) Profit and Loss Report 
and b) my Budget Report.

Now the question is, where do I go from here?


For me to be able to help you, you would need to stop thinking of 
positive and negative that way.


Double entry bookkeeping is older than the use of negative numbers in 
European mathematics. To ME, in the context of bookkeeping, positive 
means a balance in the sense expected for an account of that type and 
negative if in the sense opposite to what is expected for that sort of 
account. With the two senses being "debit" and "credit". (as opposed to 
positive and negative). Which is normal depends on the type of the 
account (or as we would say in the old days, on which side of the ledger 
-- picture an open book; there is a left hand page and a right hand page).


So . I would consider a income amount negative were it a debit and 
an expense amount negative were it a credit (say a rebate). That's  
because normal for account type income is credit and normal for account 
type expense is debit. Notice it is different say for the bank account 
involved as the other side of these transactions, but that is because 
its type is "asset".


When reporting a bug, I would suggest FIRST seeing if this bug manifests 
while using just the formal accounting senses debit and credit. If not, 
but you perceive the problem when using positive and negative, give 
serious consideration that the problem is not with the program but 
misunderstanding how positive and negative apply in this situation.


Michael D Novack


___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] [Bug 798864] Budget Revalues for the Income are positive numbers.porting on select reports are wrong

2023-04-17 Thread David T. via gnucash-user
Richard,

Just a note that if you reply to Christopher's bug messages by email, the 
discussion at the bug website is incomplete. You and the community would be 
better served by your replying in the bug itself.

David T.​

On Apr 17, 2023, 11:02, at 11:02, Richard Lindgren  
wrote:
>Sounds like you understand my problem. However, since I'm not a
>programmer, I hesitate to tackle this patch. Maybe it is easier than it
>looks and is probably the best fix? I'm just nervous here.
>
>Let me ask this basic question. When I am creating my Budget, I have
>assumed this:
>1. All Income values are positive numbers.
>2. All Expense values are negative numbers.
>
>With that being said and used, my reports work for; a) Profit and Loss
>Report and b) my Budget Report.
>
>Now the question is, where do I go from here?
>
>Richard
>
>-Original Message-
>From: bugs-ad...@bugs.gnucash.org 
>Sent: Monday, April 17, 2023 12:19 AM
>To: rlindgr...@outlook.com
>Subject: [Bug 798864] Budget Reporting on select reports are wrong
>
>https://bugs.gnucash.org/show_bug.cgi?id=798864
>
>--- Comment #7 from Christopher Lam  ---
>Created attachment 374682
>  --> https://bugs.gnucash.org/attachment.cgi?id=374682=edit
>candidate patch
>
>Here's a candidate replacement for budget-income-statement.scm, or the
>patch pasted below. You can overwrite the budget-income-statement.scm
>somewhere into the Program Files\gnucash\etc...\ (you'll need admin
>access).
>
>It changes the definition of net-income from simple summation to a
>recalculation of balances of both income and expense budget amounts. I
>think this is the correct fix.
>
>modified   gnucash/report/reports/standard/budget-income-statement.scm
>@@ -428,7 +428,11 @@
>   (gnc:get-assoc-account-balances-total expense-account-balances))
>
>  (net-income
>-  (gnc:collector- revenue-total expense-total))
>+  (gnc:collector-
>+   (gnc:get-assoc-account-balances-total
>+(get-assoc-account-balances-budget
>+ budget (append revenue-accounts expense-accounts)
>+ period-start period-end
>gnc:budget-account-get-net
>
>  (table-env
>   (list
>
>--
>You are receiving this mail because:
>You are on the CC list for the bug.
>You reported the bug.
>___
>gnucash-user mailing list
>gnucash-user@gnucash.org
>To update your subscription preferences or to unsubscribe:
>https://lists.gnucash.org/mailman/listinfo/gnucash-user
>-
>Please remember to CC this list on all your replies.
>You can do this by using Reply-To-List or Reply-All.
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.


Re: [GNC] [Bug 798864] Budget Revalues for the Income are positive numbers.porting on select reports are wrong

2023-04-17 Thread Richard Lindgren
Sounds like you understand my problem. However, since I'm not a programmer, I 
hesitate to tackle this patch. Maybe it is easier than it looks and is probably 
the best fix? I'm just nervous here.

Let me ask this basic question. When I am creating my Budget, I have assumed 
this:
1. All Income values are positive numbers.
2. All Expense values are negative numbers.

With that being said and used, my reports work for; a) Profit and Loss Report 
and b) my Budget Report.

Now the question is, where do I go from here?

Richard

-Original Message-
From: bugs-ad...@bugs.gnucash.org 
Sent: Monday, April 17, 2023 12:19 AM
To: rlindgr...@outlook.com
Subject: [Bug 798864] Budget Reporting on select reports are wrong

https://bugs.gnucash.org/show_bug.cgi?id=798864

--- Comment #7 from Christopher Lam  --- Created 
attachment 374682
  --> https://bugs.gnucash.org/attachment.cgi?id=374682=edit
candidate patch

Here's a candidate replacement for budget-income-statement.scm, or the patch 
pasted below. You can overwrite the budget-income-statement.scm somewhere into 
the Program Files\gnucash\etc...\ (you'll need admin access).

It changes the definition of net-income from simple summation to a 
recalculation of balances of both income and expense budget amounts. I think 
this is the correct fix.

modified   gnucash/report/reports/standard/budget-income-statement.scm
@@ -428,7 +428,11 @@
   (gnc:get-assoc-account-balances-total expense-account-balances))

  (net-income
-  (gnc:collector- revenue-total expense-total))
+  (gnc:collector-
+   (gnc:get-assoc-account-balances-total
+(get-assoc-account-balances-budget
+ budget (append revenue-accounts expense-accounts)
+ period-start period-end gnc:budget-account-get-net

  (table-env
   (list

--
You are receiving this mail because:
You are on the CC list for the bug.
You reported the bug.
___
gnucash-user mailing list
gnucash-user@gnucash.org
To update your subscription preferences or to unsubscribe:
https://lists.gnucash.org/mailman/listinfo/gnucash-user
-
Please remember to CC this list on all your replies.
You can do this by using Reply-To-List or Reply-All.