Bug description
I am running Firefly III version 4.7.5.3
I recently found a bug in my autoimport-tools and noticed that files with only one line were ignored because of the "has-headers": true, property in the import config file. I ended up deleting all transactions from 2018-05-01 till today and when importing all those months again, I get these errors:
Row #0 ("[from_redacted] - [uniqueid_redacted] Faell.bis:20.07.18 [subject_redacted]") could not be imported. It already exists.
Using configuration file: config/[redacted].json
Import into user: #1 ([redacted])
Type of import: file
Created job "v9hCn1GrUuyn"
File content saved.
Job configuration saved.
The has started. The process is not visible. Please wait.
Import has finished. Please wait for storage of data.
Job has finished.
154 transaction(s) have been imported.
You can find your transactions under tag "Import with key 'v9hCn1GrUuyn'"
1 error(s) occurred:
- Row #139 ("[from_redacted] - [uniqueid_redacted] Faell.bis:20.07.18 [subject_redacted]") could not be imported. It already exists.
I have tried:
php artisan ca:clhttps://[redacted]/flushrm -rf bootstrap/cache/*I have searched by:
amount_lessamount_moreAny ideas?
I believe the transaction was not "completely" removed from the DB when everything was deleted.
Thanks in advance
The duplicate detector will remember old transactions. This is by design, but it can be prevented by removing the appropriate rows from the table journal_meta.
Find entries with the name ImportHashV2 having a time and date in the deleted_at column. Those entries belong to journals that you no longer have in the system.
Once deleted, the import should work.
Thanks, it worked!, I removed all the "deleted" transactions and the import went through. Thanks for the quick fix!
@JC5 I've been having issues with this when testing CSV importing (and deleting the result), could it be possible to get a button in the admin area under "Options > Profiles > Delete ALL your deleted imports"?
For reference the PostgreSQL query I am running is DELETE FROM "journal_meta" WHERE "name" = 'import_hash_v2' AND "deleted_at" IS NOT NULL
Most helpful comment
The duplicate detector will remember old transactions. This is by design, but it can be prevented by removing the appropriate rows from the table
journal_meta.Find entries with the name
ImportHashV2having a time and date in thedeleted_atcolumn. Those entries belong to journals that you no longer have in the system.Once deleted, the import should work.