Tuesday, 18 March 2014

Can’t drop schema because it is being referenced by object…

 
Are you getting the below error when you try to drop schemas? Here is a trick to drop such schema.

 

Run the below query to find out what are the objects associates with the relevant schema and reassign objects to a different schema.

SELECT * FROM sys.objects
WHERE name = 'TEMP102913I'
and schema_id = SCHEMA_ID('sysadm');

No comments:

Post a Comment