Bug 515355

Summary: Transaction Finder not respecting criteria
Product: [Applications] kmymoney Reporter: Eleazar <eaglexboy>
Component: generalAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: NEEDSINFO WAITINGFORINFO    
Severity: major    
Priority: NOR    
Version First Reported In: 5.2.1   
Target Milestone: ---   
Platform: Appimage   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Account Filter Selection
Payee Filter
Results
Results 5.1

Description Eleazar 2026-01-31 18:21:29 UTC
Created attachment 189103 [details]
Account Filter Selection

SUMMARY
When performing a transaction search the results given are not following all the selected criteria


STEPS TO REPRODUCE
1. Click on "Find Transaction"
2. Select criteria for search (ex. Account, Dates, Payee, etc)
3. Click on find

OBSERVED RESULT
Results returned only have one criteria applied

EXPECTED RESULT
Results should have all selected criteria applied

SOFTWARE/OS VERSIONS
(available in the Info Center app, or by running `kinfo` in a terminal window)
Linux/KDE Plasma: Kubuntu 25.10 (Wayland; kernel 6.17.0.8-generic (64-bit))
KDE Plasma Version: 6.4.5
KDE Frameworks Version: 6.17.0
Qt Version: 6.9.2

ADDITIONAL INFORMATION
I noticed it in AppImage version kmymoney-5.2-4959-linux-gcc-x86_64 but I verified with latest version (kmymoney-5.2-5210-linux-gcc-x86_64) and it was still there.

The way I am testing this is I select one account and one payee (see screenshots)  and everything else is defaulted (all options are selected/no extra filters applied) and click on search and in the results I get all transactions that are filtered based on payee. Also, the "Accounts" column show transactions by account and catergories which is confusing.
Comment 1 Eleazar 2026-01-31 18:22:14 UTC
Created attachment 189104 [details]
Payee Filter

Screenshot of payee selection
Comment 2 Eleazar 2026-01-31 18:23:30 UTC
Created attachment 189105 [details]
Results

As you can see in the screenshot, the results are only filtered by payees and account column shows accounts and catergories
Comment 3 Jack 2026-01-31 19:28:55 UTC
Are you aware that internally, Categories are treated by the program as a special type of Account, to it is not surprising the Categories show up in the Account column.
I have changed the component in the bug header, as this is an issue within the ledger code, and is not simply a UI issue.
When providing version numbers, please use what is displayed by Help/About KMyMoney and not just the appimage file name.   The former should provide the commit the build is based on.  The file name includes a sequential build number, but this does not easily convert to a build date.
Now, to your problem - are there any accounts other than Checking included in the results?  I suspect not, and that if you look at the details for any of those rows showing a Category, the transaction IS in the Checking Account.  All the category rows are for the "other" splits of those transactions.  If you look carefully, I suspect the decrease and increase columns show the same amount for adjacent rows - it is just that a row is shown for each split in the transaction, not just one row per transaction.  Off the top of my head, I am not aware of a way to prevent this and only show one row per transaction.
Comment 4 Eleazar 2026-02-02 00:09:44 UTC
So for build info first image I saw this (kmymoney-5.2-4959-linux-gcc-x86_64) is 5.2.1-be4919f and latest appimage  (kmymoney-5.2-5210-linux-gcc-x86_64) it is 5.2.1-fcf114a.

>> are there any accounts other than Checking included in the results?
Yes but not shown in the screenshot since there were a lot of rows but I suspect you are correct Jack. For the rows where another account show up they were transfers between accounts and seeing that the other lines, which are the categories,  they add up to the line above.

>> Off the top of my head, I am not aware of a way to prevent this and only show one row per transaction.
It use to be possible in 5.1 (see attached 5.1 screenshot)
Comment 5 Eleazar 2026-02-02 00:10:04 UTC
Created attachment 189150 [details]
Results 5.1