-
Notifications
You must be signed in to change notification settings - Fork 276
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
atlas schema clean in Azure SQL Server #3269
Comments
Hello @AnielaN994, can you please share what kind of Or simple DDL that can reproduce the issue, thanks. |
For example, I have a view and a synonym under schema 'example' and atlas is trying to drop the schema before dropping the underlying synonym and view and it returns the error "mssql: Cannot drop schema 'example' because it is being referenced by object 'synonym' or "mssql: Cannot drop schema 'example' because it is being referenced by object 'view' |
I think I've understood why this is happening, it's due to atlas not creating a drop command from the synonyms, I recreated it with simple DDLs: create schema test; create table test.table1 ([KEY] int) CREATE VIEW test.view1 AS CREATE SYNONYM test.testsynonym FOR test.view1 and when running atlas schema clean, I get: |
Atlas-CLI doesn't support |
When will synonyms be supported ? |
Can you please explain the use-case of this object? We don't have the plan for it currently, but can priority for it if you need it to adapt Atlas-CLI to your team. |
We can't commit to ETA on GitHub issue tracker. @AnielaN994, it looks like you're trying to migrate a large (legacy?) schema to Atlas. We can assist with that, work closely with you (e.g., Slack connect), and set up the integration to address any missing features. If this sounds interesting, feel free to drop us a message using intercom on our website. |
Hello, We concluded we won't use synonyms anymore. We'll check internally and come back regarding the assistance from you, thanks!! Best Regards, |
Hello,
When I try to drop the database objects with 'atlas schema clean -u' it seems it's not creating a proper order for dropping, for example dropping first the synonyms/views then their schema and I get messages like "mssql: Cannot drop schema 'example' because it is being referenced by object 'EXAMPLE' and then I go into SQL Server and drop the objects manually in order to be able to run the script which is a bit difficult to do for a lot of objects.
Is there anything we can do for this?
Thanks.
The text was updated successfully, but these errors were encountered: