Bug 212097

Summary: Reports ignore categories in split transactions
Product: [Unmaintained] kmymoney2 Reporter: Gioele Barabucci <dev>
Component: generalAssignee: KMyMoney Development Team <kmymoney2-developer>
Status: RESOLVED WORKSFORME    
Severity: normal CC: asoliverez
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=395327
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Gioele Barabucci 2009-10-27 19:41:23 UTC
Version:           1.0.2 (using KDE 4.3.2)
OS:                Linux
Installed from:    Ubuntu Packages

Reports will not take into account values found in split transactions.

For example, if category "Books" contains two transactions, one of
€10 value and another of €5 value (the latter found in a split
transaction together with a €2 transaction in the "Shipping costs"
category), a report will show only the €10 transaction under the
"Book" category.
Comment 1 Alvaro Soliverez 2009-10-27 21:05:06 UTC
Which report are you looking at? Did you apply any filter or customization to the report?
Comment 2 Gioele Barabucci 2009-10-28 14:54:34 UTC
A custom report: there are the details

Rows/Columns:
  Organize by: month
  Show columns: number, payee, account
  (everything else deselected)
Text:
  (nothing)
Account:
  (only one Asset account)
Date:
  Range: all dates
Amount:
  (nothing selected)
Category:
  Two income category, one expense category
Payee:
  (all selected)
  Select transactions without payees: non checked
Details:
  Type: all types
  State: all states
  Validity: any transaction

The values that are not counted are from the category in "Expense". The values are shown and counted when the category is used in a normal (non-split) transaction.
Comment 3 Alvaro Soliverez 2009-10-28 15:05:32 UTC
I need to know which report you based your report on.

As a general note, the reports do not know anything about split or non-split transactions, so the issue has to be lying around on how the filters are applied based on the base report.
Comment 4 Alvaro Soliverez 2009-10-28 15:06:45 UTC
I want to confirm one thing.

Where did you install it from? Because Jaunty does not have an official 1.0.2 package, only Karmic does, but it has not been released yet.
Comment 5 Gioele Barabucci 2009-10-28 15:37:36 UTC
Sincerely I cannot recall which report I based this report on. Anyway, this is the report (with a cut-off date) as saved in the KML file:

  <REPORT datelock="userdefined" comment="" charttype="" tax="0"
          querycolumns="number,payee,account" chartgridlines="1"
          includestransfers="0" chartdatalabels="1" investments="0"
          chartbydefault="0" columnsaredays="0" rowtype="month"
          convertcurrency="1" group="Transazioni" type="querytable 1.14"
          id="R000007" includeunused="0" name="XXXXX" includeschedules="0"
          loans="0" favorite="1" includesactuals="0" >
   <ACCOUNT id="A000001" />
   <CATEGORY id="A000011" />
   <CATEGORY id="A000081" />
   <CATEGORY id="A000078" />
   <DATES from="2009-10-01" />
  </REPORT>

If this is not enough I will try to recreate the report from scratch.

I'm using Ubuntu 9.10 Karmic RC.
Comment 6 Alvaro Soliverez 2009-10-29 00:20:44 UTC
That report is based on a Transactions by Month report. I tried it here, and it filters ok even it the transaction has multiple splits.

Please keep in mind that the transactions have to comply with all the filters conditions. So, if there is a transaction that fits the category filter, but not the accounts one, then it won't be included.

If you still have a problem, please save your file as an anonymous file (ending in .anon.xml), compress it and send it to me. It will strip all personal data and scramble the numbers, but it is good enough for me to find the error.
Comment 7 Gioele Barabucci 2009-10-29 13:11:22 UTC
I tried to replicate the bug in a blank KMyMoney file and I found that, in fact, the problem was in my choice of the category filters. Sorry for the noise.
Comment 8 Alvaro Soliverez 2009-10-30 03:29:41 UTC
Perhaps you could use the "Cash Flow Transactions this Month" for what you want. The "Transactions by Category" report might fit too.