-
Notifications
You must be signed in to change notification settings - Fork 5
Not require foreignKey.reference.resource
for self-referencing
#29
Conversation
Deploying datapackage with Cloudflare Pages
|
Why not always require |
@peterdesmet |
I was suggesting to have the resource name, even for an internal relationship. So for a resource called "foreignKeys": [
{
"fields": "parentEventID",
"reference": {
"resource": "events", <-- Not "" or "self", just the resource name
"fields": "eventID"
}
}
] |
@peterdesmet |
I really like @peterdesmet 's self-referencing approach, but what do we do if it is a standalone schema definition (i.e. defined in a json outside of a datapackage)? We could encounter the situation where two resources of different names to point to the same external schema... That said, I think this is more an argument against external schemas, rather than this approach to |
VETOED by WG I'll create an updated PR based on @peterdesmet's solution |
Let's have one last try here according to this comment - frictionlessdata/datapackage#37 (comment) |
I'm sorry to reopen the discussion. 😄 Can you adapt this PR? The spec indeed removes the requirement, but the text currently uses |
@peterdesmet |
@peterdesmet |
@roll I approve this PR. |
Thanks @peterdesmet ! |
Looks good to me. |
Change looks good to me! |
Thanks! ACCEPTED by WG (6/9) |
foreignKey.reference.resource
for self-referencing datapackage#878Rationale
Please see the linked issue