Support for incremental import of planning data from M3

The SCV M3 Import program has been improved to support incremental import of planning data from M3. The program now accepts these new input parameters:

  • TARGET_DELETE_MODE: Specifies if the existing data in the target table must be deleted before importing new data. Possible values are "Physical" or "None". Default is "Physical".
  • TARGET_UPDATE_MODE: Specifies if the newly imported records must be inserted or merged into the target table. Possible values are "Insert" or "Merge". Default is "Insert".

The two new parameters can be used to support different scenarios, such as holding the complete data set in the target table or only the changed data. The target update mode Merge is only available if an SCV PK constraint is defined on the target table.

It is now possible to specify EPOCH values as input parameters in BOIs. The <DATE_VALUE> tag in the SCV BOI definition has the following structure:

<DATE_VALUE>

<TYPE></TYPE>

<!-- Data Value Alternatives -->

<KEYWORD_VALUE></KEYWORD_VALUE>

<PARAMETER_VALUE></PARAMETER_VALUE>

<CONSTANT_VALUE></CONSTANT_VALUE>

<OFFSET>

<!-- Offset Value Alternatives -->

<PARAMETER_VALUE></PARAMETER_VALUE>

<CONSTANT_VALUE></CONSTANT_VALUE>

<OFFSET_TYPE></OFFSET_TYPE>

</OFFSET>

</DATE_VALUE>

The possible values for the <TYPE> tag already included YEAR, MONTH, DAY, HOUR, MINUTE. Now it is possible to specify a date value of type EPOCH. The expected data type for the specified EPOCH values is bigint.

The new EPOCH time can be used together with incremental imports using the keywords WINDOW_START or WINDOW_END. Consider the following example:

<BOI>

<PROGRAM>PPP</PROGRAM>

<TRANSACTION>TTT</TRANSACTION>

<STAGING_TABLE>SSS</STAGING_TABLE>

<INPUT_FIELD>

<FIELD>FFF</FIELD>

<DATE_VALUE>

<TYPE>EPOCH</TYPE>

<KEYWORD_VALUE>#WINDOW_START#</KEYWORD_VALUE>

</DATE_VALUE>

</INPUT_FIELD>

<BOI>

When executing this sample BOI in incremental mode, the SCV snapshot manager creates a new snapshot log record for the table TTT. The M3 import program retrieves the window start time from the newly created snapshot log record, converts it to EPOCH time, and passes the final value in milliseconds to the M3 input field FFF.

Currently, the EPOCH type is not used in any standard SCV BOIs.

Note: This feature is available on upgrade. You are not required a new role or privilege access to use this feature.