SQL SERVER 2005删除维护作业报错:The DELETE statement conflicted with the REFERENCE constraint "FK_subplan_jo
来源:互联网 发布:苹果手机上的编程软件 编辑:程序博客网 时间:2024/04/28 05:38
下面是网上找的一些资料来解决这个问题:
先获取这个job_id:
USE [msdb]GO/****** Object: Job [dbbackup_diff.Subplan_1] Script Date: 04/08/2015 10:22:46 ******/EXEC msdb.dbo.sp_delete_job @job_id=N'588acfb8-630b-41c3-aa47-90d3671bda90', @delete_unused_schedule=1GO
根据job_id到subplan_id:
select subplan_id FROM msdb.dbo.sysmaintplan_subplans where job_id='588acfb8-630b-41c3-aa47-90d3671bda90'subplan_idFE56B397-4704-4AA7-BE49-767C1574E7D0
从系统表msdb.dbo.sysmaintplan_log和msdb.dbo.sysmaintplan_subplans中分别删除subplan_id为‘FE56B397-4704-4AA7-BE49-767C1574E7D0’的记录:
delete from msdb.dbo.sysmaintplan_log where subplan_id='FE56B397-4704-4AA7-BE49-767C1574E7D0'
delete FROM msdb.dbo.sysmaintplan_subplans WHERE SUBPLAN_ID='FE56B397-4704-4AA7-BE49-767C1574E7D0'
再次回到图形界面再删除job就不会报错了。
参考:
http://www.cnblogs.com/kerrycode/p/3852231.html
0 0
- SQL SERVER 2005删除维护作业报错:The DELETE statement conflicted with the REFERENCE constraint "FK_subplan_jo
- Msg 547 The ALTER TABLE statement conflicted with the CHECK constraint "".
- The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_SortId".
- Microsoft SQL Server 2005: The Complete Reference
- SQL SERVER 2008删除维护计划作业
- The With Statement
- 配置JNDI 报错 The reference to entity "characterEncoding" must end with the ';' delimiter
- java报错:The reference to entity "characterEncoding" must end with the ';' delimiter.
- 关于cas client报错 The reference to entity "locale" must end with the ';' delimiter.
- java报错:The reference to entity "characterEncoding" must end with the ';' delimiter.
- java报错:The reference to entity "characterEncoding" must end with the ';' delimiter.
- 报错:Couldn't register with the bootstrap server
- ambari安装报错Registration with the server failed.
- [MSSQL]SQL Server 2008 Using the MERGE statement
- mybatis 项目配置 xml文件时 报错提示(The reference to entity "useSSL" must end with the ';' delimiter.)
- mybatis 项目配置 xml文件时 报错提示(The reference to entity "useSSL" must end with the ';'
- SQL: The Complete Reference
- SQL: The Complete Reference
- android NFC学习笔记(三)
- 面试题之_01(字符串包含)
- java json字符串转JSONObject和JSONArray以及取值
- js函数传值ie下的bug
- iOS企业版程序发布--升级
- SQL SERVER 2005删除维护作业报错:The DELETE statement conflicted with the REFERENCE constraint "FK_subplan_jo
- Linux 网络编程——TCP 和 UDP 数据报格式详解
- Python中定义“私有”成员变量和成员函数
- 开启博客之路 纪录辛勤点滴
- Win7复制CMD窗口中的内容
- BZOJ 2331 SCOI2011 地板 插头DP
- 框架层理解Activity生命周期(APP启动过程)
- 怎么实现ppt格式文件转换成pdf格式
- 项目开发流程