很久不上来了? 一上来就有东西看.
解决方案 »
- win7家庭版安装aql2000
- SQL2000的数据库被锁了,求解决办法
- 如何有条件解决控制treeview的子结点的显示问题!treeview并没有disable或visible属性
- 无法登入CSDN 提示--未将对象引用设置到对象实例
- 连接数据库时不能执行select语句,其它的update,insert,delete执行正常,看有没有解决的办法?
- 就业......我该怎么面对。
- 紧急求助:部分数据读取慢 怀疑是数据库的问题
- 关于SQLSERVER 游标递归的问题
- 请教关于group by 的用法及方法,谢谢!急~~~~~~~!!!
- 求助sql
- 如何从外部access库中取某表指定纪录更新到SQL-SERVER中某表中对应纪录?急!!!
- 关于SQL递归!!!!!
create table A (id int primary key)
go
create table B(id int,
constraint fk_B_A foreign key (id) references A (id))
go
create table C(id int,
constraint fk_C_A foreign key (id) references A (id))
go
insert A values (1)
insert B values(1)
insert C values (1)--1:
delete a
/*****
服务器: 消息 547,级别 16,状态 1,行 1
DELETE statement conflicted with COLUMN REFERENCE constraint 'fk_B_A'. The conflict occurred in database 'pubs', table 'B', column 'id'.
The statement has been terminated.
*******/--2:
begin tran
exec fk_switch 'A',0
delete A
exec fk_switch 'A',1
rollback
/*
alter table B nocheck constraint fk_B_A
alter table C nocheck constraint fk_C_A(所影响的行数为 1 行)alter table B check constraint fk_B_A
alter table C check constraint fk_C_A
*/--3: 清除测试表
drop table A,B,C
go