USE [POSMST]
GO

ALTER DATABASE [POSMST] SET AUTO_CLOSE OFF WITH NO_WAIT
GO

IF NOT EXISTS (SELECT * FROM sys.columns WHERE object_id = OBJECT_ID(N'dbo.MST_ITEM') AND name='TAX_AMT_INCLUDE_YN')
BEGIN
   ALTER TABLE MST_ITEM ADD TAX_AMT_INCLUDE_YN VARCHAR(1) NULL;
END
GO

--#17143 [해피오더]자동 주문 처리 개선 start
IF NOT EXISTS (SELECT * FROM sys.columns WHERE object_id = OBJECT_ID(N'dbo.MST_ITEM') AND name='EXE_HPORD')
BEGIN
   ALTER TABLE MST_ITEM ADD TAX_AMT_INCLUDE_YN VARCHAR(1) NULL;
   ALTER TABLE MST_ITEM ADD EXE_HPORD VARCHAR(1) NULL;
   ALTER TABLE MST_KDS_ORD_MSG ADD F_CNT INT NULL;
END
GO
--#17143 [해피오더]자동 주문 처리 개선 end

IF NOT EXISTS (SELECT * FROM sys.columns WHERE object_id = OBJECT_ID(N'dbo.MST_KDS_ORD_MSG') AND name='F_CNT')
BEGIN
   ALTER TABLE MST_KDS_ORD_MSG ADD F_CNT INT NULL;
END
GO
