 
 GO
 
-/****** Object:  StoredProcedure [dbo].[Company_Delete]    Script Date: 5/23/2017 5:21:28 PM ******/
-
-SET ANSI_NULLS ON
-
-GO
-
-SET QUOTED_IDENTIFIER ON
-
-GO
-
-IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[Company_Delete]') AND type in (N'P', N'PC'))
-
-BEGIN
-
-EXEC dbo.sp_executesql @statement = N'CREATE PROCEDURE [dbo].[Company_Delete] AS' 
-
-END
-
-GO
-
-
-
-ALTER PROCEDURE [dbo].[Company_Delete]
+/****** Object:  StoredProcedure [dbo].[Company_Delete]    Script Date: 6/5/2017 5:22:06 PM ******/
+
+SET ANSI_NULLS ON
+
+GO
+
+SET QUOTED_IDENTIFIER ON
+
+GO
+
+
+
+CREATE PROCEDURE [dbo].[Company_Delete]
 
 @Id INT 
 


GO

IF  EXISTS (SELECT * FROM sys.foreign_keys WHERE object_id = OBJECT_ID(N'[dbo].[FK_dbo.AspNetUserLogins_dbo.AspNetUsers_UserId]') AND parent_object_id = OBJECT_ID(N'[dbo].[AspNetUserLogins]'))

ALTER TABLE [dbo].[AspNetUserLogins] CHECK CONSTRAINT [FK_dbo.AspNetUserLogins_dbo.AspNetUsers_UserId]

GO

IF NOT EXISTS (SELECT * FROM sys.foreign_keys WHERE object_id = OBJECT_ID(N'[dbo].[FK_dbo.AspNetUserRoles_dbo.AspNetRoles_RoleId]') AND parent_object_id = OBJECT_ID(N'[dbo].[AspNetUserRoles]'))

ALTER TABLE [dbo].[AspNetUserRoles]  WITH CHECK ADD  CONSTRAINT [FK_dbo.AspNetUserRoles_dbo.AspNetRoles_RoleId] FOREIGN KEY([RoleId])

REFERENCES [dbo].[AspNetRoles] ([Id])


) ON [PRIMARY]

GO

/****** Object:  Table [dbo].[AspNetUserClaims]    Script Date: 6/5/2017 5:22:06 PM ******/

SET ANSI_NULLS ON

GO

SET QUOTED_IDENTIFIER ON

GO

CREATE TABLE [dbo].[AspNetUserClaims](

	[Id] [int] IDENTITY(1,1) NOT NULL,

	[UserId] [nvarchar](128) NOT NULL,

	[ClaimType] [nvarchar](max) NULL,

	[ClaimValue] [nvarchar](max) NULL,

 CONSTRAINT [PK_dbo.AspNetUserClaims] PRIMARY KEY CLUSTERED 

