USE Installations02_Def
GO

INSERT [dbo].[tblDtsFields] ([nID], [tTableName], [nTableDSType], [tName], [nDataViewID], [nDataType], [nDataSize], [tCaption], [fChoiceOrder], [fRequired], [tFieldValuesTable], [nValueTableDSType], [fEnabled], [fKeepHistory], [fCanQueryBy], [tDestinationTab], [fEditable], [fVisible], [nRelatedField], [tLabelCaption], [tAliasSourceTable], [tBoundControlName], [nDestinationTabID], [tWhere], [fIncludeInDefaultReports], [nRelationshipType], [nContainerType], [nControlType], [tValueTableIDFld], [tValueTableNameFld], [nRevisionNumber], [tOrigCaption]) VALUES (822, N'tblDts', 32, N'License_Key_2', 1, 10, 255, N'License Key 2', 0, 0, NULL, NULL, 1, 1, 1, NULL, 1, 1, NULL, N'License Key 2', NULL, N'txt_822_License_Key_2', 1, NULL, 0, -1, 1, NULL, NULL, NULL, 2, NULL)
INSERT [dbo].[tblDtsFields] ([nID], [tTableName], [nTableDSType], [tName], [nDataViewID], [nDataType], [nDataSize], [tCaption], [fChoiceOrder], [fRequired], [tFieldValuesTable], [nValueTableDSType], [fEnabled], [fKeepHistory], [fCanQueryBy], [tDestinationTab], [fEditable], [fVisible], [nRelatedField], [tLabelCaption], [tAliasSourceTable], [tBoundControlName], [nDestinationTabID], [tWhere], [fIncludeInDefaultReports], [nRelationshipType], [nContainerType], [nControlType], [tValueTableIDFld], [tValueTableNameFld], [nRevisionNumber], [tOrigCaption]) VALUES (823, N'tblDts', 32, N'License_Key_3', 1, 10, 255, N'License Key 3', 0, 0, NULL, NULL, 1, 1, 1, NULL, 1, 1, NULL, N'License Key 3', NULL, N'txt_823_License_Key_3', 1, NULL, 0, -1, 1, NULL, NULL, NULL, 2, NULL)
GO

USE Installations02_Dat
GO

ALTER TABLE tblDts ADD [License_Key_2] [nvarchar](255) NULL,
	[License_Key_3] [nvarchar](255) NULL
GO


USE Users_mdb
GO

INSERT [dbo].[tblFieldMap_ImpRule] ([nID], [tInternalFieldName], [tInternalTableName], [nInternalDSID], [tExternalFieldName], [nValueTableID], [tExternalFieldFormat], [bForeignKey], [bSyncOnlyNewRecord], [nCVLookupMode]) VALUES (32, N'License_Key_2', N'tblDts', 32, N'License_Key', 0, 'GetLicenseKey', 0, 0, 0)
INSERT [dbo].[tblFieldMap_ImpRule] ([nID], [tInternalFieldName], [tInternalTableName], [nInternalDSID], [tExternalFieldName], [nValueTableID], [tExternalFieldFormat], [bForeignKey], [bSyncOnlyNewRecord], [nCVLookupMode]) VALUES (32, N'License_Key_3', N'tblDts', 32, N'License_Key', 0, 'GetLicenseKey', 0, 0, 0)

UPDATE [tblFieldMap_ImpRule] SET [tExternalFieldFormat]='GetLicenseKey' WHERE nID=32 AND [tInternalFieldName]='License_Key'
GO
