cuiyi's blog(崔毅 crazycy)

          記錄點(diǎn)滴 鑒往事之得失 以資于發(fā)展
          數(shù)據(jù)加載中……

          The database principal owns a schema in the database, and cannot be dropped

          Use UI to configure database, also checked some items in schema;
          while delete this user, an error encounter like this: The database principal owns a schema in the database, and cannot be dropped. (Microsoft SQL Server, Error: 15138)
           
          but use the below script, I successfully removed;
          SELECT s.name
          FROM sys.schemas s
          WHERE s.principal_id = USER_ID('YourUserID');

          find all the schemas to be removed
          ALTER AUTHORIZATION ON SCHEMA::YourSchemaName TO dbo;

          posted on 2013-07-11 17:34 crazycy 閱讀(390) 評(píng)論(0)  編輯  收藏 所屬分類(lèi): DBMS

          主站蜘蛛池模板: 临清市| 隆德县| 屯昌县| 南昌县| 凤台县| 汉寿县| 托克逊县| 耒阳市| 桓仁| 哈尔滨市| 十堰市| 肇庆市| 陆良县| 泸定县| 丹棱县| 彭山县| 潢川县| 卓尼县| 那曲县| 全州县| 崇阳县| 西峡县| 东丰县| 财经| 梓潼县| 大丰市| 屯昌县| 虎林市| 平罗县| 福建省| 巴南区| 玉龙| 靖西县| 庄浪县| 扎鲁特旗| 南通市| 芦溪县| 莱西市| 周口市| 永城市| 郧西县|