Bug 514307 - QIF importer interprets payee SSA as opening balance
Summary: QIF importer interprets payee SSA as opening balance
Status: RESOLVED FIXED
Alias: None
Product: kmymoney
Classification: Applications
Component: importer (other bugs)
Version First Reported In: git (master)
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: KMyMoney Devel Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-01-08 04:42 UTC by bnbunch
Modified: 2026-01-24 04:04 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In: 5.2.2
Sentry Crash Report:


Attachments
Error During import Payee Name changed to "Opening balance" (33.39 KB, image/png)
2026-01-08 04:42 UTC, bnbunch
Details
Debug report.docx (31.88 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2026-01-09 02:17 UTC, bnbunch
Details
attachment-2686980-0.html (2.49 KB, text/html)
2026-01-09 02:59 UTC, bnbunch
Details
attachment-3652232-0.html (2.32 KB, text/html)
2026-01-24 04:04 UTC, bnbunch
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bnbunch 2026-01-08 04:42:12 UTC
Created attachment 188309 [details]
Error During import Payee Name changed to "Opening balance"

Problem with consistency from an incorrect payee import
Payee "Aldo" caused to be imported as Opening balance transaction dated 01/05/2026
Payee as "Opening Balance" which changed opening balance of imported account to 01/05/26
This caused consistency check transactions prior to 01/05/2026
Tried changing "ALDO" to "Aldo" with same results thought might be issue
Changed payee from "ALDO" to "Aldo-MIsc"
imported again after deleting previous import and resetting opening balance date
and No consistency error
Had same error while back and changed Payee then and no more error as long as payee changed
Any idea of cause ??
Comment 1 Thomas Baumgart 2026-01-08 09:30:51 UTC
Do you have a payee called "Opening balance"? What is the content of the tab "Matching" for this payee? 

BTW: the attached screen shot does not provide any details for the cause of what has happened. A much better source of information would be the console output during the import/matching phase. Can you provide that (by re-doing the import)?
Comment 2 bnbunch 2026-01-09 02:17:26 UTC
Created attachment 188341 [details]
Debug report.docx

Matching is       ^Aldo$
No payee named "Opening Balances "
See attached Word Doc file including
 QIF file
See Output window you requested
And Ledger Capture showing import of 3 transactions , one is the "Opening
Balance"
Output window log only shows the other 2 imported

On Thu, Jan 8, 2026 at 3:30 AM Thomas Baumgart <bugzilla_noreply@kde.org>
wrote:

> https://bugs.kde.org/show_bug.cgi?id=514307
>
> Thomas Baumgart <tbaumgart@kde.org> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>              Status|REPORTED                    |NEEDSINFO
>          Resolution|---                         |WAITINGFORINFO
>
> --- Comment #1 from Thomas Baumgart <tbaumgart@kde.org> ---
> Do you have a payee called "Opening balance"? What is the content of the
> tab
> "Matching" for this payee?
>
> BTW: the attached screen shot does not provide any details for the cause of
> what has happened. A much better source of information would be the console
> output during the import/matching phase. Can you provide that (by re-doing
> the
> import)?
>
> --
> You are receiving this mail because:
> You reported the bug.
Comment 3 bnbunch 2026-01-09 02:59:53 UTC
Created attachment 188342 [details]
attachment-2686980-0.html

Changed payee name "Aldo" to "Aldo X"
Imported perfectly if this helps
Don't know why but now remember having to do the same with another payee
sometime back

On Thu, Jan 8, 2026 at 8:17 PM Brady Mattison <bnbunch@gmail.com> wrote:

> Matching is       ^Aldo$
> No payee named "Opening Balances "
> See attached Word Doc file including
>  QIF file
> See Output window you requested
> And Ledger Capture showing import of 3 transactions , one is the "Opening
> Balance"
> Output window log only shows the other 2 imported
>
> On Thu, Jan 8, 2026 at 3:30 AM Thomas Baumgart <bugzilla_noreply@kde.org>
> wrote:
>
>> https://bugs.kde.org/show_bug.cgi?id=514307
>>
>> Thomas Baumgart <tbaumgart@kde.org> changed:
>>
>>            What    |Removed                     |Added
>>
>> ----------------------------------------------------------------------------
>>              Status|REPORTED                    |NEEDSINFO
>>          Resolution|---                         |WAITINGFORINFO
>>
>> --- Comment #1 from Thomas Baumgart <tbaumgart@kde.org> ---
>> Do you have a payee called "Opening balance"? What is the content of the
>> tab
>> "Matching" for this payee?
>>
>> BTW: the attached screen shot does not provide any details for the cause
>> of
>> what has happened. A much better source of information would be the
>> console
>> output during the import/matching phase. Can you provide that (by
>> re-doing the
>> import)?
>>
>> --
>> You are receiving this mail because:
>> You reported the bug.
>
>
Comment 4 bnbunch 2026-01-22 03:28:22 UTC
QIF File:

!Account
NLNB 8052
TBank
^
!Type:Bank
D1/21/2026
U2139.30
T2139.30
C*
PSSA
LSSA
^
D1/21/2026
U-78.41
T-78.41
C*
PMetronet
LUtility:internet
^

*******************************************
QIF file shows 2 transactions

Output window below only shows 1 imported
2nd transaction shows as Opening Balances as category and account
opening date is changed to Todays date an get consistency error because of this

Payee SSA imported as category "Opening balance"
No Payee
*********************************************************
Register shows as follows
Date		Payee		Category		Withdrawal	Deposit
01/21/26			Opening Balance				2139.30
01/21/26	Metronet	Utility			78.41

_________________________________________________________________________________________________________
SSA does not show in output window you requested



Output Window Below:

KMyMoneyPlugin::KMMStatementInterface::import start
Importing statement for  "LNB 8052"
Processing transactions (LNB 8052)
Process on: '2026-01-21', id: '2026-01-21-c27e8b4-1', symbol: '', amount: '-78.41', fees: '0.00'
Start matching payee "Metronet"
Located match for "Metronet" "P000333" with "^Metronet$" for 8 chars
Done matching payee "Metronet" , Result:
Single match: "Metronet" "P000333"
Looking for a match with transaction:  "2026-01-21" , "Metronet" , "-78.41" (referenced account:  "LNB 8052" )
Considering 0 existing transaction(s) for matching
Looking for a match with transaction:  "2026-01-21" , "Metronet" , "-78.41" (referenced account:  "LNB 8052" )
Considering 23 schedule(s) for matching the transaction
Processing transactions done (LNB 8052)
Processed home view section 8 in 1 ms
Processed home view section 1 in 14 ms
Processed home view section 2 in 3 ms
Processed home view section 3 in 5 ms
Processed home view section 4 in 3 ms
Processed home view section 5 in 4 ms
Processed home view section 6 in 241 ms
Processed home view section 7 in 4 ms
Processed home view section 10 in 6 ms
Importing statement for 'LNB 8052' done
Model for "T" loaded with 1 items in 0 ms
current selection
Institutions: ("I000004")
Accounts: ("A000152")
JournalEntries: ("2026-01-21-T000000000000002473-S0001")
Comment 5 Jack 2026-01-23 01:14:06 UTC
Please, when you reply to a bug by email, please trim EVERYTHING except your response as your ENTIRE message becomes the next comment in the bug, and the extra copy of what you are replying to (the previous comment) makes it harder to follow the flow of the bug.
Also, when replying, you need to set the status back to REPORTED, or it may get missed by the folks most able to assist.  I'm adjusting the status now.
Comment 6 Thomas Baumgart 2026-01-23 15:11:56 UTC
The payee SSA in the first transaction is incorrectly treated as opening transaction because it is contained in the string "Eröffnungssaldo" which is the default of a very old setting which most likely leads back to a version 3.x or 4.x of KMyMoney. It was implemented to support national versions of QIF files but somehow the GUI for the settings was removed but the underlying logic is still around.

I will remove the (German) default values with the next build. You can achieve the same with this workaround: 

add the following section to the end of your ~/.config/kmymoney/kmymoneyrc file while KMyMoney is not active (I have no idea where this file is kept on Windows):

[QIF Options]
qifCash=
qifBank=
qifCreditCard=
qifAsset=
qifOpeningBalance=
qifInvoice=
Comment 7 Thomas Baumgart 2026-01-23 15:17:38 UTC
Git commit f56fda57ef2851b8a6bac676678c469c4d903c7c by Thomas Baumgart.
Committed on 23/01/2026 at 15:16.
Pushed by tbaumgart into branch 'master'.

Don't provide defaults that cannot be changed through GUI

The GUI to change these values was apparently dropped a long time ago
but the old defaults can cause trouble. Removing them basically disables
the feature and does not interfere anymore.

In case the feature is needed at any time, we need to implement a GUI or
the user can set those values by adding the following section to the
~/.config/kmymoney/kmymoneyrc file with the required values on the right
side of the assignment:

---8<---
[QIF Options]
qifCash=
qifBank=
qifCreditCard=
qifAsset=
qifOpeningBalance=
qifInvoice=
---8<---
FIXED-IN: 5.2.2

M  +6    -6    kmymoney/settings/kmymoney.kcfg

https://invent.kde.org/office/kmymoney/-/commit/f56fda57ef2851b8a6bac676678c469c4d903c7c
Comment 8 Thomas Baumgart 2026-01-23 15:19:50 UTC
Git commit cb1830757eaaf640a199b5637a27258fdd041ab8 by Thomas Baumgart.
Committed on 23/01/2026 at 15:17.
Pushed by tbaumgart into branch '5.2'.

Don't provide defaults that cannot be changed through GUI

The GUI to change these values was apparently dropped a long time ago
but the old defaults can cause trouble. Removing them basically disables
the feature and does not interfere anymore.

In case the feature is needed at any time, we need to implement a GUI or
the user can set those values by adding the following section to the
~/.config/kmymoney/kmymoneyrc file with the required values on the right
side of the assignment:

---8<---
[QIF Options]
qifCash=
qifBank=
qifCreditCard=
qifAsset=
qifOpeningBalance=
qifInvoice=
---8<---
FIXED-IN: 5.2.2
(cherry picked from commit f56fda57ef2851b8a6bac676678c469c4d903c7c)

M  +6    -6    kmymoney/settings/kmymoney.kcfg

https://invent.kde.org/office/kmymoney/-/commit/cb1830757eaaf640a199b5637a27258fdd041ab8
Comment 9 bnbunch 2026-01-24 04:04:41 UTC
Created attachment 188841 [details]
attachment-3652232-0.html

Thanks for the Info Tried editing kmymoneyrc with added option with no luck
Recently found the download kmymomey master 5176 Version 5.2.1-cb18307
No Longer have this issue All Payees I was having troubles seem to import
correctly now

Thanks for the update

On Fri, Jan 23, 2026 at 9:11 AM Thomas Baumgart <bugzilla_noreply@kde.org>
wrote:

> https://bugs.kde.org/show_bug.cgi?id=514307
>
> Thomas Baumgart <tbaumgart@kde.org> changed:
>
>            What    |Removed                     |Added
>
> ----------------------------------------------------------------------------
>              Status|REPORTED                    |CONFIRMED
>      Ever confirmed|0                           |1
>
> --- Comment #6 from Thomas Baumgart <tbaumgart@kde.org> ---
> The payee SSA in the first transaction is incorrectly treated as opening
> transaction because it is contained in the string "Eröffnungssaldo" which
> is
> the default of a very old setting which most likely leads back to a
> version 3.x
> or 4.x of KMyMoney. It was implemented to support national versions of QIF
> files but somehow the GUI for the settings was removed but the underlying
> logic
> is still around.
>
> I will remove the (German) default values with the next build. You can
> achieve
> the same with this workaround:
>
> add the following section to the end of your ~/.config/kmymoney/kmymoneyrc
> file
> while KMyMoney is not active (I have no idea where this file is kept on
> Windows):
>
> [QIF Options]
> qifCash=
> qifBank=
> qifCreditCard=
> qifAsset=
> qifOpeningBalance=
> qifInvoice=
>
> --
> You are receiving this mail because:
> You reported the bug.