fix: dataset update uniqueness (#25756)

This commit is contained in:
Beto Dealmeida
2023-10-25 16:49:32 -04:00
committed by GitHub
parent cee8532733
commit c7f8d11a7e
3 changed files with 92 additions and 2 deletions

View File

@@ -89,7 +89,10 @@ class UpdateDatasetCommand(UpdateMixin, BaseCommand):
table_name = self._properties.get("table_name", None)
# Validate uniqueness
if not DatasetDAO.validate_update_uniqueness(
self._model.database_id, self._model_id, table_name
self._model.database_id,
self._model.schema,
self._model_id,
table_name,
):
exceptions.append(DatasetExistsValidationError(table_name))
# Validate/Populate database not allowed to change