IF OBJECT_ID('EST_PARAM_COMPRAS_GRUPO') IS NULL 
begin
CREATE TABLE [dbo].[EST_PARAM_COMPRAS_GRUPO](
	[CD_CTR] [int] IDENTITY(1,1) NOT NULL,
	[DS_GRP_PARAMETRO] [varchar](150) NOT NULL,
	[CD_USU] [int] NOT NULL,
	[DT_CAD] [datetime] NOT NULL,
	[DT_ULT_ALT] [datetime] NULL,
 CONSTRAINT [PK_EST_PARAM_COMPRAS_GRUPO] PRIMARY KEY CLUSTERED 
(
	[CD_CTR] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]

ALTER TABLE [dbo].[EST_PARAM_COMPRAS_GRUPO] ADD  CONSTRAINT [DF_EST_PARAM_COMPRAS_GRUPO_DS_GRP_PARAMETRO]  DEFAULT ('') FOR [DS_GRP_PARAMETRO]

ALTER TABLE [dbo].[EST_PARAM_COMPRAS_GRUPO] ADD  CONSTRAINT [DF_EST_PARAM_COMPRAS_GRUPO_CD_USU]  DEFAULT ((0)) FOR [CD_USU]

ALTER TABLE [dbo].[EST_PARAM_COMPRAS_GRUPO] ADD  CONSTRAINT [DF_EST_PARAM_COMPRAS_GRUPO_DT_CAD]  DEFAULT (getdate()) FOR [DT_CAD]
end

