CREATE TABLE [dbo].[claim_mvts]
(
[cmvt_mvt_code] [dbo].[ais_code_short] NOT NULL,
[cmvt_l1] [nvarchar] (64) COLLATE French_CI_AS NOT NULL,
[cmvt_l2] [nvarchar] (64) COLLATE French_CI_AS NULL,
[cmvt_l3] [nvarchar] (64) COLLATE French_CI_AS NULL,
[cmvt_type_code] [dbo].[ais_code_short] NOT NULL,
[cmvt_default] [bit] NOT NULL CONSTRAINT [DF__claim_mvts__cmvt_default] DEFAULT ((0))
) ON [PRIMARY]
ALTER TABLE [dbo].[claim_mvts] ADD
CONSTRAINT [CK__claim_mvts_cmvt_mvt_code__string_pk] CHECK ((len(ltrim(rtrim([cmvt_mvt_code])))>(0) AND charindex('*',[cmvt_mvt_code])=(0) AND charindex('%',[cmvt_mvt_code])=(0)))
GO
ALTER TABLE [dbo].[claim_mvts] ADD CONSTRAINT [PK_claim_mvts] PRIMARY KEY CLUSTERED  ([cmvt_mvt_code]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[claim_mvts] ADD CONSTRAINT [FK_claim_mvts_nm_types_mvts_clm] FOREIGN KEY ([cmvt_type_code]) REFERENCES [dbo].[nm_types_mvts_clm] ([nmtmclm_type_code])
GO
