
CREATE TABLE [MIG_FILE_DEFAULTS](
	[ZZ_ID] [int] IDENTITY(0,1) NOT NULL,
	[TEMPLATE_ID] [int] NOT NULL,
	[DB_ZZ_ID] [smallint] NULL,
	[ZZ_COUNTER] [smallint] NULL,
	[DSET_KEY] [varchar](40) NULL,
	[REVISION] [varchar](6) NULL,
	[DSET_NAME] [varchar](255) NULL,
	[AREA_KEY] [varchar](30) NULL,
	[FORMAT] [smallint] NULL,
	[TITLE_TYPE] [smallint] NULL,
	[PROJECT_ID] [varchar](15) NULL,
	[DESCRIPTION] [varchar](60) NULL,
	[STORAGE_ID] [varchar](10) NULL,
	[ORIG_AREA_KEY] [varchar](30) NULL,
	[CLASSIFICATION] [smallint] NULL,
	[PAGE_SIZE] [smallint] NULL,
	[PAGE_NO] [smallint] NULL,
	[SCALE] [smallint] NULL,
	[INTEGER1] [int] NULL,
	[INTEGER2] [int] NULL,
	[INTEGER3] [int] NULL,
	[INTEGER4] [int] NULL,
	[INTEGER5] [int] NULL,
	[STRING1] [varchar](32) NULL,
	[STRING2] [varchar](32) NULL,
	[STRING3] [varchar](32) NULL,
	[STRING4] [varchar](32) NULL,
	[STRING5] [varchar](32) NULL,
	[OBJECT_TYPE] [smallint] NULL,
	[LOCKED_BY] [varchar](20) NULL,
	[LOCKED_DATE] [int] NULL,
	[LOCKED_TIME] [smallint] NULL,
	[ORIGINATING_APP] [smallint] NULL,
	[AUTHOR] [varchar](20) NULL,
	[FILE_TYPE] [smallint] NULL,
	[ORIG_FILE_KEY] [varchar](40) NULL,
	[ORIG_FILE_GEN] [varchar](6) NULL,
	[ORIG_FILE_NAME] [varchar](255) NULL,
	[FILE_SIZE] [int] NULL,
	[FILE_MODIFIED_DATE] [int] NULL,
	[FILE_MODIFIED_TIME] [smallint] NULL,
	[FILE_CREATED_DATE] [int] NULL,
	[FILE_CREATED_TIME] [smallint] NULL,
	[DATE1] [int] NULL,
	[DATE2] [int] NULL,
	[DATE3] [int] NULL,
	[LIST1] [smallint] NULL,
	[LIST2] [smallint] NULL,
	[LIST3] [smallint] NULL,
	[DERIVED_FROM] [varchar](40) NULL,
	[DERIVED_FROM_REV] [varchar](6) NULL,
	[CAD_ENV] [smallint] NULL,
	[FILE_CLASS] [smallint] NULL,
	[MAPPING_RULES] [varchar](255) NULL,
	[ARCHIVED] [smallint] NULL,
	[ARCHIVE_DATE] [int] NULL,
	[ARCHIVE_TIME] [smallint] NULL,
	[WITH_THUMBNAIL] [smallint] NULL,
	[UPDATED_ON] [datetime2](7) NULL,
	-- [EXT_COMPUTED]  AS (right([DSET_NAME],case when charindex('.',reverse([DSET_NAME]))>(0) then charindex('.',reverse([DSET_NAME]))-(1) else charindex('.',reverse([DSET_NAME])) end)),
	[D001] [nvarchar](max) NULL,
 CONSTRAINT [PK_MIG_FILE_DEFAULTS_IDX] PRIMARY KEY CLUSTERED 
(
	[ZZ_ID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]



