Bug 475247

Summary: Cheque number field kmmSplits.checkNumber is too small
Product: [Applications] kmymoney Reporter: David <solbeziel>
Component: databaseAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version: 5.1.3   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In:

Description David 2023-10-05 14:59:08 UTC
SUMMARY
***
Table kmmSplits, column checkNumber is declared as VARCHAR(32), however my banking system is creating entries with cheque numbers like "BALANCE_CASHBACK-2xxxxxxd-5xx6-4xxc-8xxd-9xxxxxxxxxx2"
***


STEPS TO REPRODUCE
1. Create transaction with long cheque number (such as the example)
2. Save As to SQL

OBSERVED RESULT
Save As will fail, reporting that the data is too large for the checkNumber field.

EXPECTED RESULT
Transaction is saved into the database as entered without truncation or errors. (except in the case of an obscenely long entry)

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Kubuntu 23.04
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.104.0
Qt Version: 5.15.8

ADDITIONAL INFORMATION
Using the KMyMoney Tools menu, select the "Generate SQL" tool and copy the generated code to a text editor. Searching for checkNumber verifies that the field is VARCHAR(32). I recommend that it be changed in future versions to VARCHAR(64).