- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
The entity_table attribute in the config file uses a distinct form of a table object. Its primary objective is to define and load unique entities into the Data Product from a delimited file or database table. As a secondary function, it will also be implicitly included with the other_tables for loading of data via parsers.
Attribute - unique_keys
{
"table_alias": "eeee",
"table": "../somewhere-outside-the-project-repo/eeee.csv",
// Unique keys define distinct entities
//
"unique_keys": [
"kkkk", // A column representing a unique entity ID in the source table
... // If multiple unique_keys are specified, they will be combined
]
}
Attribute - foreign_keys
{
"table_alias": "eeee",
"table": "../somewhere-outside-the-project-repo/eeee.csv",
"unique_keys": [
"kkkk"
],
// Foreign keys define how other table objects can map data to entities
// Unique keys are implicitly included as foreign keys
//
"foreign_keys": [
"ffff", // A column representing a unique entity ID in the source table
... // Multiple foreign keys are possible
]
}
Attribute - entities
{
"table_alias": "eeee",
"table": "../somewhere-outside-the-project-repo/eeee.csv",
"unique_keys": [
"kkkk"
],
"foreign_keys": [
"ffff"
],
// The Data Product will only load this many entities, max
//
"entities": ####
}
Attribute - dupes
{
"table_alias": "eeee",
"table": "../somewhere-outside-the-project-repo/eeee.csv",
"unique_keys": [
"kkkk"
],
"foreign_keys": [
"ffff"
],
// If "dupes" is set to "die", the system will crash and report
// if it sees a row with a duplicate copy of unique_keys
//
"dupes": "die"
}
Was this article helpful?