---
title: "Parent Child Data Migration Tool"
canonical: "https://kb.myframeworks.com.au/space/PROSTIXV48DOC/31096958/Parent%20Child%20Data%20Migration%20Tool"
format: markdown
---
> ℹ️ # <span style="color: #003366">Description of the Parent Child Data Migration Tool (Part of the </span><span style="color: #003366">[Parent Child Module](https://skb.sterland.com:8443/display/PROSTIXV48DOC/Parent+and+Child+Product+User+Guide)</span><span style="color: #003366">)</span>
> ℹ️ 
> ℹ️ In trying to implement the parent/child software, Customers may plan to use their existing product codes as the parent codes and then create linked child codes. Without doing it this way, the product stock on hand will never be accurate while outstanding transactions are being processed. Therefore, a migration tool was required which works through all existing transactions (Sales Orders, Quotes, Purchase Orders) and swaps out the parent code with the relevant child codes.
> ℹ️ 
> ℹ️ In doing this we need to ensure all quantities and pricing remains as per the original transaction.
> ℹ️ 
> ℹ️ Two utilities have been created:
> ℹ️ 
> ℹ️ 1.** cusupcpld.p** to mass update Parent Child Products
> ℹ️ 
> ℹ️ and
> ℹ️ 
> ℹ️ 2.** cusupcprdy.p** to update all Open Transactions with new Parent and Child Products and Tallies
> ℹ️ 
> ℹ️ For an explanation of each utility & how to run each utility, refer to the below sections/processes:
> ℹ️ 
> ℹ️ > Macro (toc)
> ℹ️ 
> ℹ️ 
> ℹ️ ## <span style="color: #003366">Pre-requisities</span>
> ℹ️ 
> ℹ️ 1. Ensure **FeaturePCP** is enabled in your system
> ℹ️ 2. Set up a file for the audit logs under /prostix/dmp onsite called **parentchildlogs.** This is required when running the second utility **cusupcprdy.p**.
> ℹ️ 
> ℹ️ 
> ℹ️ ## <span style="color: #003366">Mass Update Parent Child Products (cusupcpld.p)</span>  
> ℹ️   
> ℹ️ 
> ℹ️ 
> ℹ️ ### <span style="color: #003366">About the cusupcpld.p Utility</span>
> ℹ️ 
> ℹ️ This utility updates / imports the Parent products and their specific Child products. Parent products are flagged as ‘Parent’ as identified by 'Parent Header' = Yes (Product Maintenance - More Data - General Information):
> ℹ️ 
> ℹ️ ![image](media://81d501c2-9f43-45ee-b517-55bce8bc71e4)
> ℹ️ 
> ℹ️  Child products are added/updated for the parent and can be viewed within Product Maintenance - Options - Child Products:
> ℹ️ 
> ℹ️ ![image](media://8c5ce5c5-6aff-47a5-98ce-13c99746f869)
> ℹ️ 
> ℹ️ ![image](media://31b7a0cf-6131-4e34-8865-f92926edf281)
> ℹ️ 
> ℹ️ An audit report is generated that lists the products that were uploaded successfully. 
> ℹ️ 
> ℹ️ 
> ℹ️ ### <span style="color: #003366">Mass updating the Product codes to Parent Child via the </span>**<span style="color: #003366">cusupcpld.p utility</span>**
> ℹ️ 
> ℹ️ To mass update Product codes to Parent Child, perform the following:
> ℹ️ 
> ℹ️ 1. Create a .csv file of the Parent and Child Products to be updated/migrated using this csv format: 
> ℹ️ 
> ℹ️ 2. Save the file to */prostix/dmp/<filename>.csv* .
> ℹ️ 
> ℹ️ :info: The file does not need to have a set file name format.
> ℹ️ 
> ℹ️ 3. From Prostix, select menu options A-5-6, then run **cusupcpld.p** to import the .csv file created in *Step 1*.
> ℹ️ 
> ℹ️ 4. This prompt for the import filename. Enter the filename, then press <F1> to run it.
> ℹ️ 
> ℹ️ ![image](media://dbad3d91-ca8a-47da-bfc5-3c387f70cc0f)
> ℹ️ 
> ℹ️ 5. Two reports are generated from this utilty:
> ℹ️ 
> ℹ️ 1. An audit report is generated for the products successfully imported and updated:* /prostix/dmp/audit_pcp_import_*date*.csv*
> ℹ️ 2. An error report is generated for all Products that were not succesfully imported:* /prostix/dmp/parent_child_import_error.csv*
> ℹ️ 
> ℹ️ 5. Once complete, the utility pops up a completion message, however if errors do occur, you will receive this pop-up message:
> ℹ️ 
> ℹ️ ![image](media://99a7b48a-2d66-41b2-8d05-8a2290a19abf)
> ℹ️ 
> ℹ️ :info: This error log file includes a description of the error for each line not imported. Update the Product as required in ProStix, then re-try the import of the Products that failed to import previously.
> ℹ️ 
> ℹ️ 
> ℹ️ ## ** **<span style="color: #003366">Update Open Transactions (cusupcprdy.p)</span>  
> ℹ️   
> ℹ️ 
> ℹ️ 
> ℹ️ ### <span style="color: #003366">About the cusupcprdy.p Utility </span>
> ℹ️ 
> ℹ️ This utility locates any open transactions that are linked to the Parent or Child Products updated during the [Mass Update Parent Child Products](#ParentChildDataMigrationTool-massupdate) and updates all Open Sales, Quotes and Purchase Orders where any parent products are currently listed and the timber tally is defined on the order, and then replaces the parent product with the appropriate child product for each length as detailed in the tally. It also updates the stock on hand values of the Child Product/s.
> ℹ️ 
> ℹ️ 
> ℹ️ ### <span style="color: #003366">Running the cusupcprdy.p utility</span>
> ℹ️ 
> ℹ️ To run this utilty, perform the following:
> ℹ️ 
> ℹ️ 1. From Prostix select menu options A-5-6,then run **cusupcprdy.p**
> ℹ️ 
> ℹ️ ![image](media://6644ae87-9aa8-4107-be52-6208dcc9e7aa)
> ℹ️ 
> ℹ️ 2. Press <F1> to run the program.
> ℹ️ 
> ℹ️ 3. Audit logs are created under* /prostix/dmp/parentchildlogs/* . Refer to the table below for a description of the audit logs produced.
> ℹ️ 
> ℹ️ :info: Refer to [Pre-requisities ](#ParentChildDataMigrationTool-prereq)for setting up the folder on the ProStix server.
> ℹ️ 
> ℹ️ > Macro (legacy-content)

> Macro (__confluenceADFMigrationUnsupportedContentInternalExtension__)