SCV Staging table creation

The Sync SCV Configuration program creates or updates an SCV Staging table as follows:
  • Determines the corresponding SCV Staging table name:
    If <current entity>.C_IS_SYSTEM = "T" then 
        If <current entity>.C_STAGING_DIRECTION = "Import" then 
            <table name> = ST_<current entity>.C_CFG_SHORT_PREFIX_IN_<current entity>.C_NAME
        Else If <current entity>.C_STAGING_DIRECTION = "Export" then 
            <table name> = ST_<current entity>.C_CFG_SHORT_PREFIX_OUT_<current entity>.C_NAME
    
    Else 
        If <current entity>.C_STAGING_DIRECTION = "Import" then 
            <table name> = SUT_<current entity>.C_CFG_SHORT_PREFIX_IN_<current entity>.C_NAME
        Else If <current entity>.C_STAGING_DIRECTION = "Export" then 
            <table name> = SUT_<current entity>.C_CFG_SHORT_PREFIX_OUT_<current entity>.C_NAME
    
  • If the table is not available in the SCV database with the corresponding SCV Staging table name:
    • Creates an SCV table from entity definition by using this planning process, control, and custom columns specified in the staging_import_flag and staging_export_flag columns of the column registry table, for import and export:
      If <current entity>.C_STAGING_DIRECTION = "Import" then 
      Planning process columns:
          source                      NVARCHAR(80)  
      
      Control columns:
          created_by                  NVARCHAR(80)  
          creation_time               DATETIME2(7)  
          modified_by                 NVARCHAR(80)  
          modification_time           DATETIME2(7)  
      
      Custom columns:
          custom_string_1-10          NVARCHAR(80)  
          custom_number_1-10          FLOAT  
          custom_date_1-5             DATETIME2(7)  
      
      
      Else If <current entity>.C_STAGING_DIRECTION = "Export" then 
      Planning process columns:
          source                      NVARCHAR(80)  
          --
          export_status               NVARCHAR(30)  
          plan_type                   NVARCHAR(50)  
          plan_version                NVARCHAR(80)  
          plan_value_id               NVARCHAR(150)  
          plan_value_type             NVARCHAR(50)  
      
      Control columns:
          created_by                  NVARCHAR(80)  
          creation_time               DATETIME2(7)  
          modified_by                 NVARCHAR(80)  
          modification_time           DATETIME2(7)  
      
      Custom columns:
          custom_string_1-10          NVARCHAR(80)  
          custom_number_1-10          FLOAT  
          custom_date_1-5             DATETIME2(7)  
      
  • If the table name is available in the SCV database with the corresponding SCV Staging table name:
    • Updates an SCV table from entity definition if the corresponding column is not available in <table name> for each property in <current entity>.