Seed file import - super admin!

Importing complex data.

Seed file import

Lookup data can also be imported in bulk using a specialised “Seed file” importer. That importer can be found on the Data Import frontpage by clicking the import button there.



This is a very advanced feature, but also very powerful that allows for registration of not just multiple instances of a single entity but complex related data sets. For example a number of CompoundCombinations, their synonyms and batches in one file.

It requires in-depth knowledge of the organisation of entities in grit42


Seed files are tab separated files that have a specialised format. Here is an example:



The first line is the name of the Entity that is to be loaded. 

The second line is having the fields to be imported into. Hence, you will need to know the available fields for each entity.

From the third line and down, the actual values are listed. If a value field is blank, it has to be filled out with the value \N


The seed file can be much more complex. Here is an example:



Here we both create a new BacteriaSpecies, links a BacteriaStrain to the newly created BacteriaSpecies and then finally register a Bacteria linking to both the newly created BacteriaSpecies and BacteriaStrain.

Notice the special header name for the columns referring to other entities, bacteria_species_id:name. The first part before the colon is the name of the foreign key to link to, and the second part after the colon is referring to what field in the foreign entity we would like to match the value.