Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FK and unique constraints need to sit at table-level #48

Open
MandarinDuck opened this issue Mar 1, 2021 · 0 comments
Open

FK and unique constraints need to sit at table-level #48

MandarinDuck opened this issue Mar 1, 2021 · 0 comments

Comments

@MandarinDuck
Copy link

These properties need to sit outside of the column property or they won't work for composite column constraints.

"foreign_key": {
"type": "array",
"title": "The list of foreign key relationships this column has, if any",
"default": [],
"examples": [
[
{
"table": "",
"columns": []
}
]
],
"items": {
"anyOf": [
{
"type": "object",
"default": {},
"examples": [
{
"table": "",
"columns": []
}
],
"required": [
"table",
"columns"
],
"properties": {
"table": {
"type": "string",
"title": "The table name",
"default": "",
"examples": [
""
]
},
"columns": {
"type": "array",
"title": "The list of column names",
"default": []
}
},
"additionalProperties": true
}
]
}
},
"unique": {
"type": "boolean",
"title": "Specifies if the values in the column must be unique",
"default": false
},

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant