if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[mrp物料需求计算_物料编号_fk]') and OBJECTPROPERTY(id, N'IsForeignKey') = 1)
ALTER TABLE [dbo].[mrp物料需求计算] DROP CONSTRAINT mrp物料需求计算_物料编号_fk
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[m ...