Scripting for data transformation

It is now possible to define and run Python scripts in SCP MT cloud deployments for complex data transformations.

SCP implementations require complex transformations on the imported planning data to map the data to the planning and scheduling models. Such transformations often require programming capabilities. An example of these transformations is BOM collapse..

The new Scripts configuration allows users to define a script that reads input data from SCV, processes the data using Python code and writes output data back to SCV.

Scripting in SCP supports Python3. In the scripting runtime environment, the standard Python libraries and some additional libraries such as Pandas and libraries for YAML handling are available to use in the Python code.

Script configuration includes the mapping definitions for the input and output data. This structure is followed for mapping definition:
{
    "inputs": [
        {
            "filename": "<input_filename_table>",
            "table": "<SCV table name>"
        },
        {
            "filename": "<input_filename_query>",
            "query": "<valid SQL query on SCV database>"
        }
    ],
    "outputs": [
        {
            "filename": "<output_filename>",
            "table": "<SCV table name>"
        }
    ]
}