I try to import 90 records from a .txt-file into a table in: Administration > Administration Area > Periodic > Data export/import > Definition Groups
I've made a new Definition Group, set the name and type (Custom) of it and Selected the Default file name.
In the Table setup I deleted all records and selected the table where I want to import the records, Import status = Import.
After clicking on the import-button in the Definition group-window I'm getting error-messages for every record and no data is imported:
ERROR message sais: Cannot create a record in ZIP/postal Codes (CLIAddressZipCode). ZIP/postal Code: , . The record already exists.
EXAMPLE OF A RECORD:
1440;Les Frèchaux;175557;BRAINE-LE-CHÂTEAU
The 1st field is the zipcode, the 2nd is the street, the 3rd is the ID, the 4th field is the city.
UPDATE: I will try to add an if-statement: to check if the record already exists, if not the record will be inserted.
Check for unique indexes in table CLIAddressZipCode
(this is not a standard table).
This problem arises when your input contain two records which have the same values in the index fields.
The second record will throw the error when inserted saying: The record already exists.