Importing errors: The field x must contain a unique entry; record # n
When importing data, you get an error message telling you that a certain field must contain a unique entry
In every database, certain fields are designated as requiring a unique value. The only field that must ALWAYS contain a unique value is RecordNumber: every record MUST have a unique RecordNumber. You can import your own record numbers - in which case you must make sure that each one is unique, both within the import data and the data already in the database. If you don't supply a record number in your import file, CatBase will automatically assign one.
You can also designate certain other fields as Unique - for example, it is often the case that the Key Field in a table is required to be unique so that you never have two records with the same Part Number, or Model Code, or Company Name, or whatever the Key Field in that table is used for.
To change a field's Unique setting:
- Click on the Setup button on the main window and choose Table and Field setup
- Select the appropriate table from the tabs at the top of the window
- Double-click on the field in question
- This will open the Field Properties dialogue
- Note that the selected field must have Indexed option selected before it can be made Unique.
- Note also that not all field types can be made Unique (Boolean and Text fields, for example)
- One of the check boxes in Field Properties is Unique. Select this option to make a field unique; un-select it to remove the unique requirement
- Click OK to save your changes