Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sql: drop view cascade does not handle deps being dropped earlier
Fixes: cockroachdb#68600 Previously, drop view cascade would only check if a dependency was dropped when initially going over the list. It did not check before executing the drop logic, so an earlier dependency could cause the current object to move to a dropped state. This was inadequate because cascaded drops of views could fail due to this reason. To address this, this patch skips dropping dependencies if at a later stage they are found to be dropped. Release note (bug fix): Cascaded drop of views could run into 'table ...is already being dropped' errors incorrectly.
- Loading branch information