Summary: | CSV Import causes KMM to recreate every single payee even if they already exist in the payee database | ||
---|---|---|---|
Product: | [Applications] kmymoney | Reporter: | lp.allard.1 |
Component: | general | Assignee: | KMyMoney Devel Mailing List <kmymoney-devel> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | CC: | agander93, lp.allard.1 |
Priority: | NOR | ||
Version: | 4.6.4 | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
lp.allard.1
2013-11-12 12:38:41 UTC
Matching is not a function of the CSV importer. Matching occurs after the importer has finished its job, i.e. in KMM itself. If I import your sample file into a KMM file which doesn't have those payees, then the payees are created correctly. If I then re-import the same file, duplicate payees are NOT created. However, as in your case, those payees already exist (but not having been imported), when you do the import duplicates are created. I think the difference may be that in your file, those payees are set to 'don't match' and that is why duplicates are created. However, when the payees are created by KMM, they are set to match. I think the logic is that, if they already exist but are not set to match, then that is what the user wants. "I think the difference may be that in your file, those payees are set to 'don't match' and that is why duplicates are created" If there is some sort of switch somewhere to match or not match payees, then I fully agree, this is not a bug but an unclear feature. When you say "in your file" do you mean in the CSV file or in the kmy file? (In reply to comment #2) > "I think the difference may be that in your file, those payees are set to > 'don't match' and that is why duplicates are created" > > If there is some sort of switch somewhere to match or not match payees, then > I fully agree, this is not a bug but an unclear feature. > > When you say "in your file" do you mean in the CSV file or in the kmy file? Sorry, I meant in your kmy file. If you look in Payees view on the left then select a payee, on the right there is a 'Matching' tab where you may select whether/how to match. No Match is pretty obvious, as is 'Payee name'. Then, you may import a file where the payee has additional characters appended, so the third choice allows for these, with, regex-type matching. The easiest way to handle these is to select the 'new' payee and select delete. If the payee is actually being used, it will ask if you want to substitute another payee. If so, select that payee and its entries will be moved over, and the original payee's matching detail will have been amended appropriately. OK I have seen this "Transaction matching" in the payee list. I can modify one payee at a time and select "Match on payee name" and click update, but can I do it for all payees in one shot? That will be long to modify 968 payees one by one.... (In reply to comment #4) > OK I have seen this "Transaction matching" in the payee list. I can modify > one payee at a time and select "Match on payee name" and click update, but > can I do it for all payees in one shot? > > That will be long to modify 968 payees one by one.... Yes, indeed. I don't know of a way from within KMM to do this. It is possible to multi-select payees, which gives the impression that it might work, but it doesn't. I'm afraid. The way I would attempt to tackle this is with search and replace in an editor that can handle XML format, such as Kate or Kwrite. First, and of utmost importance, TAKE a BACKUP! Then save your file in XML format. Open it in your editor, and search for <PAYEE matchingenabled="0", and replace with <PAYEE matchingenabled="1". Just try it with one or two payees then save that file and load into KMM, which recognises XML format. If those payees look right, proceed to do them all. Once KMM look correct save again, but in .kmy format. I've just tested the procedure and it works, but do take care. Crystal clear explanations!!!! (In reply to comment #6) > Crystal clear explanations!!!! I suppose you could achieve the same via your SQL. |