specs
specs copied to clipboard
Create new type `table`
This new JTS type will be identical to array
, except it will have a mandatory attribute schema
which will contain a valid JSON Table Schema for the items in the array.
For example:
"schema": {
"fields": [
{ "name": "tender-id", "type": "string", "constraints": {"required": true} },
{ "name": "tender-documents",
"type": "table",
"schema": {
"fields": [
{ "name": "document-date", "type": "date"},
{ "name": "document-title", "type": "string"},
{ "name": "document-url", "type": "string", "format": "uri"}
]
}
}
]
}
@akariv i like the idea but sense this is post v1.0. Could you do a PR to add this as a pattern in the mean time?
+1 on this.
See my comment at https://github.com/frictionlessdata/specs/issues/409#issuecomment-930029124
Noting that this implementation maps well onto document-based data backends that support nesting (mongodb, Elasticsearch) and a version of this is already implemented in https://github.com/frictionlessdata/tableschema-elasticsearch-py