text: 
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Table (AccessLevel,ACTriggerLength,AD_Client_ID,AD_Org_ID,AD_Table_ID,CopyColumnsFromTable,Created,CreatedBy,EntityType,ImportTable,IsActive,IsAutocomplete,IsChangeLog,IsDeleteable,IsHighVolume,IsSecurityEnabled,IsView,LoadSeq,Name,ReplicationType,TableName,Updated,UpdatedBy) VALUES ('2',0,0,0,540697,'N',TO_TIMESTAMP('2016-01-19 14:43:15','YYYY-MM-DD HH24:MI:SS'),100,'de.metas.product','N','Y','N','N','Y','N','N','N',0,'Produkt-Zuordnung','L','M_Product_Mapping',TO_TIMESTAMP('2016-01-19 14:43:15','YYYY-MM-DD HH24:MI:SS'),100)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Table_Trl (AD_Language,AD_Table_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Table_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Table t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Table_ID=540697 AND NOT EXISTS (SELECT * FROM AD_Table_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Table_ID=t.AD_Table_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  CREATE SEQUENCE M_PRODUCT_MAPPING_SEQ INCREMENT 1 MINVALUE 0 MAXVALUE 2147483647 START 1000000
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Sequence (AD_Client_ID,AD_Org_ID,AD_Sequence_ID,Created,CreatedBy,CurrentNext,CurrentNextSys,Description,IncrementNo,IsActive,IsAudited,IsAutoSequence,IsTableID,Name,StartNewYear,StartNo,Updated,UpdatedBy) VALUES (0,0,554267,TO_TIMESTAMP('2016-01-19 14:43:15','YYYY-MM-DD HH24:MI:SS'),100,1000000,50000,'Table M_Product_Mapping',1,'Y','N','Y','Y','M_Product_Mapping','N',1000000,TO_TIMESTAMP('2016-01-19 14:43:15','YYYY-MM-DD HH24:MI:SS'),100)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552990,102,0,19,540697,'AD_Client_ID',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Mandant fÃ¼r diese Installation.','de.metas.product',10,'Ein Mandant ist eine Firma oder eine juristische Person. Sie kÃ¶nnen keine Daten Ã¼ber Mandanten hinweg verwenden. .','Y','N','N','N','N','Y','N','N','Y','N','N','Mandant',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552990 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552991,113,0,19,540697,'AD_Org_ID',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Organisatorische Einheit des Mandanten','de.metas.product',10,'Eine Organisation ist ein Bereich ihres Mandanten - z.B. Laden oder Abteilung. Sie kÃ¶nnen Daten Ã¼ber Organisationen hinweg gemeinsam verwenden.','Y','N','N','N','N','Y','N','N','Y','N','N','Sektion',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552991 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552992,245,0,16,540697,'Created',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Datum, an dem dieser Eintrag erstellt wurde','de.metas.product',29,'Das Feld Erstellt zeigt an, zu welchem Datum dieser Eintrag erstellt wurde.','Y','N','N','N','N','Y','N','N','Y','N','N','Erstellt',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552992 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Reference_Value_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552993,246,0,18,110,540697,'CreatedBy',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Nutzer, der diesen Eintrag erstellt hat','de.metas.product',10,'Das Feld Erstellt durch zeigt an, welcher Nutzer diesen Eintrag erstellt hat.','Y','N','N','N','N','Y','N','N','Y','N','N','Erstellt durch',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552993 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552994,348,0,20,540697,'IsActive',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Der Eintrag ist im System aktiv','de.metas.product',1,'Es gibt zwei MÃ¶glichkeiten, einen Datensatz nicht mehr verfÃ¼gbar zu machen: einer ist, ihn zu lÃ¶schen; der andere, ihn zu deaktivieren. Ein deaktivierter Eintrag ist nicht mehr fÃ¼r eine Auswahl verfÃ¼gbar, aber verfÃ¼gbar fÃ¼r die Verwendung in Berichten. Es gibt zwei GrÃ¼nde, DatensÃ¤tze zu deaktivieren und nicht zu lÃ¶schen: (1) Das System braucht den Datensatz fÃ¼r Revisionszwecke. (2) Der Datensatz wird von anderen DatensÃ¤tzen referenziert. Z.B. kÃ¶nnen Sie keinen GeschÃ¤ftspartner lÃ¶schen, wenn es Rechnungen fÃ¼r diesen GeschÃ¤ftspartner gibt. Sie deaktivieren den GeschÃ¤ftspartner und verhindern, dass dieser Eintrag in zukÃ¼nftigen VorgÃ¤ngen verwendet wird.','Y','N','N','N','N','Y','N','N','Y','N','Y','Aktiv',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552994 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552995,607,0,16,540697,'Updated',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Datum, an dem dieser Eintrag aktualisiert wurde','de.metas.product',29,'Aktualisiert zeigt an, wann dieser Eintrag aktualisiert wurde.','Y','N','N','N','N','Y','N','N','Y','N','N','Aktualisiert',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552995 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Reference_Value_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552996,608,0,18,110,540697,'UpdatedBy',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'Nutzer, der diesen Eintrag aktualisiert hat','de.metas.product',10,'Aktualisiert durch zeigt an, welcher Nutzer diesen Eintrag aktualisiert hat.','Y','N','N','N','N','Y','N','N','Y','N','N','Aktualisiert durch',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552996 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Element (AD_Client_ID,AD_Element_ID,AD_Org_ID,ColumnName,Created,CreatedBy,EntityType,IsActive,Name,PrintName,Updated,UpdatedBy) VALUES (0,542944,0,'M_Product_Mapping_ID',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'de.metas.product','Y','Produkt-Zuordnung','Produkt-Zuordnung',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Description,Help,Name,PO_Description,PO_Help,PO_Name,PO_PrintName,PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Element_ID, t.Description,t.Help,t.Name,t.PO_Description,t.PO_Help,t.PO_Name,t.PO_PrintName,t.PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=542944 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,EntityType,FieldLength,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552997,542944,0,13,540697,'M_Product_Mapping_ID',TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,'de.metas.product',10,'Y','N','N','N','Y','Y','N','N','Y','N','N','Produkt-Zuordnung',0,TO_TIMESTAMP('2016-01-19 14:43:22','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552997 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,AllowZoomTo,ColumnName,Created,CreatedBy,DDL_NoForeignKey,Description,EntityType,FieldLength,Help,IsActive,IsAdvancedText,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsCalculated,IsDimension,IsEncrypted,IsGenericZoomKeyColumn,IsGenericZoomOrigin,IsIdentifier,IsKey,IsLazyLoading,IsMandatory,IsParent,IsSelectionColumn,IsStaleable,IsSyncDatabase,IsTranslated,IsUpdateable,IsUseDocSequence,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552998,620,0,10,540697,'N','Value',TO_TIMESTAMP('2016-01-19 14:43:42','YYYY-MM-DD HH24:MI:SS'),100,'N','SuchschlÃ¼ssel fÃ¼r den Eintrag im erforderlichen Format - muss eindeutig sein','de.metas.product',255,'A search key allows you a fast method of finding a particular record.
  If you leave the search key empty, the system automatically creates a numeric number.  The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_<TableName>", where TableName is the actual name of the table (e.g. C_Order).','Y','N','Y','N','N','N','N','N','N','N','N','N','N','N','N','Y','N','N','N','Y','N','SuchschlÃ¼ssel',0,TO_TIMESTAMP('2016-01-19 14:43:42','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:43
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552998 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 14:44
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  UPDATE AD_Table SET IsChangeLog='Y', IsHighVolume='Y',Updated=TO_TIMESTAMP('2016-01-19 14:44:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=540697
  ;
  
  -- 19.01.2016 14:48
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,AllowZoomTo,ColumnName,Created,CreatedBy,DDL_NoForeignKey,EntityType,FieldLength,IsActive,IsAdvancedText,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsCalculated,IsDimension,IsEncrypted,IsGenericZoomKeyColumn,IsGenericZoomOrigin,IsIdentifier,IsKey,IsLazyLoading,IsMandatory,IsParent,IsSelectionColumn,IsStaleable,IsSyncDatabase,IsTranslated,IsUpdateable,IsUseDocSequence,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,552999,542944,0,30,208,'N','M_Product_Mapping_ID',TO_TIMESTAMP('2016-01-19 14:48:25','YYYY-MM-DD HH24:MI:SS'),100,'N','de.metas.product',10,'Y','N','Y','N','N','N','N','N','N','N','N','N','N','N','N','N','N','N','N','Y','N','Produkt-Zuordnung',0,TO_TIMESTAMP('2016-01-19 14:48:25','YYYY-MM-DD HH24:MI:SS'),100,0)
  ;
  
  -- 19.01.2016 14:48
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=552999 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID)
  ;
  
  -- 19.01.2016 15:23
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Index_Table (AD_Client_ID,AD_Index_Table_ID,AD_Org_ID,AD_Table_ID,Created,CreatedBy,Description,EntityType,IsActive,IsUnique,Name,Processing,Updated,UpdatedBy,WhereClause) VALUES (0,540372,0,208,TO_TIMESTAMP('2016-01-19 15:23:58','YYYY-MM-DD HH24:MI:SS'),100,'A product may have only one pendant per org','de.metas.product','Y','Y','M_Product_M_ProductMapping_ID','N',TO_TIMESTAMP('2016-01-19 15:23:58','YYYY-MM-DD HH24:MI:SS'),100,'IsActive')
  ;
  
  -- 19.01.2016 15:23
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Index_Table_Trl (AD_Language,AD_Index_Table_ID, ErrorMsg, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Index_Table_ID, t.ErrorMsg, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Index_Table t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Index_Table_ID=540372 AND NOT EXISTS (SELECT * FROM AD_Index_Table_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Index_Table_ID=t.AD_Index_Table_ID)
  ;
  
  -- 19.01.2016 15:24
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Index_Column (AD_Client_ID,AD_Column_ID,AD_Index_Column_ID,AD_Index_Table_ID,AD_Org_ID,Created,CreatedBy,EntityType,IsActive,SeqNo,Updated,UpdatedBy) VALUES (0,1404,540743,540372,0,TO_TIMESTAMP('2016-01-19 15:24:15','YYYY-MM-DD HH24:MI:SS'),100,'de.metas.product','Y',10,TO_TIMESTAMP('2016-01-19 15:24:15','YYYY-MM-DD HH24:MI:SS'),100)
  ;
  
  -- 19.01.2016 15:24
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  INSERT INTO AD_Index_Column (AD_Client_ID,AD_Column_ID,AD_Index_Column_ID,AD_Index_Table_ID,AD_Org_ID,Created,CreatedBy,EntityType,IsActive,SeqNo,Updated,UpdatedBy) VALUES (0,552999,540744,540372,0,TO_TIMESTAMP('2016-01-19 15:24:35','YYYY-MM-DD HH24:MI:SS'),100,'de.metas.product','Y',20,TO_TIMESTAMP('2016-01-19 15:24:35','YYYY-MM-DD HH24:MI:SS'),100)
  ;
  
  -- 19.01.2016 15:24
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  UPDATE AD_Index_Table SET WhereClause='IsActive=''Y''',Updated=TO_TIMESTAMP('2016-01-19 15:24:48','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Index_Table_ID=540372
  ;
  
  COMMIT;
  
  
  -- 19.01.2016 14:44
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  CREATE TABLE M_Product_Mapping (AD_Client_ID NUMERIC(10) NOT NULL, AD_Org_ID NUMERIC(10) NOT NULL, Created TIMESTAMP WITH TIME ZONE NOT NULL, CreatedBy NUMERIC(10) NOT NULL, IsActive CHAR(1) CHECK (IsActive IN ('Y','N')) NOT NULL, M_Product_Mapping_ID NUMERIC(10) NOT NULL, Updated TIMESTAMP WITH TIME ZONE NOT NULL, UpdatedBy NUMERIC(10) NOT NULL, Value VARCHAR(255) DEFAULT NULL , CONSTRAINT M_Product_Mapping_Key PRIMARY KEY (M_Product_Mapping_ID))
  ;
  
  
  -- 19.01.2016 14:48
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  ALTER TABLE M_Product ADD M_Product_Mapping_ID NUMERIC(10) DEFAULT NULL 
  ;
  
  ALTER TABLE M_Product ADD CONSTRAINT MProductMapping_MProduct FOREIGN KEY (M_Product_Mapping_ID) REFERENCES M_Product_Mapping DEFERRABLE INITIALLY DEFERRED;
  
  -- 19.01.2016 15:24
  -- I forgot to set the DICTIONARY_ID_COMMENTS System Configurator
  CREATE UNIQUE INDEX M_Product_M_ProductMapping_ID ON M_Product (AD_Org_ID,M_Product_Mapping_ID) WHERE IsActive='Y'
  ;
  
  