can any one explain what below code means
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_ht_litigatio n_ht_mast]') and OBJECTPROPERTY( id, N'IsForeignKey' ) = 1)
ALTER TABLE [dbo].[ht_litigation] DROP CONSTRAINT FK_ht_litigatio n_ht_mast
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_ht_mutation_ Ht_mast]') and OBJECTPROPERTY( id, N'IsForeignKey' ) = 1)
ALTER TABLE [dbo].[ht_mutation] DROP CONSTRAINT FK_ht_mutation_ Ht_mast
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_Ht_tran_Ht_m ast]') and OBJECTPROPERTY( id, N'IsForeignKey' ) = 1)
ALTER TABLE [dbo].[Ht_tran] DROP CONSTRAINT FK_Ht_tran_Ht_m ast
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Ht_mast]') and OBJECTPROPERTY( id, N'IsUserTable') = 1)
drop table [dbo].[Ht_mast]
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_ht_litigatio n_ht_mast]') and OBJECTPROPERTY( id, N'IsForeignKey' ) = 1)
ALTER TABLE [dbo].[ht_litigation] DROP CONSTRAINT FK_ht_litigatio n_ht_mast
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_ht_mutation_ Ht_mast]') and OBJECTPROPERTY( id, N'IsForeignKey' ) = 1)
ALTER TABLE [dbo].[ht_mutation] DROP CONSTRAINT FK_ht_mutation_ Ht_mast
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_Ht_tran_Ht_m ast]') and OBJECTPROPERTY( id, N'IsForeignKey' ) = 1)
ALTER TABLE [dbo].[Ht_tran] DROP CONSTRAINT FK_Ht_tran_Ht_m ast
GO
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Ht_mast]') and OBJECTPROPERTY( id, N'IsUserTable') = 1)
drop table [dbo].[Ht_mast]
GO
Comment