Delete Inactive Digital Factories¶
Your aPriori installation includes a script to efficiently remove inactive Digital Factories, to reduce the size of your aPriori database, saving memory and optimizing aPriori performance. You can delete all or selected inactive Digital Factories.
The script can delete baseline Digital Factories that are both:
- Marked as inactive by the import of a newer baseline digital factory
- Not included in the overlay (inheritance) structure of a customer Digital Factory.
Note:
This script does not delete any customer Digital Factories.
Good Practice¶
- This script must be run when no users are logged into aPriori. By default, when the script is executed all inactive and non-inherited Digital Factories in the deployment will be deleted.
- aPriori recommends that you run this script during the upgrade process. However, this is not mandatory; the script can be run on your database at any time.
Run the Script¶
To use the script, follow these steps:
- Open a Command Prompt window and use the cd command to navigate to your installation's bin directory, for example, type cd C:\apriori\bin.
-
Optionally, generate a list of your inactive Digital Factories:
Enter the following in your Command Prompt window:
deleteInactiveDFs.cmd -DcreateInactiveList=file pathname -Dapriori.user=username ‑Dapriori.password=password
This exports a .csv file that lists all your inactive Digital Factories and saves it in the location specified by file pathname.
Note that file pathname is the full pathname of a .csv file that the script will create, for example, C:\my_df_info\inactive_dfs.csv.
Note also that username and password are your aPriori username and password.
This step is optional, but aPriori recommends that you review this list to ensure you do not inadvertently delete a Digital Factory that still is wanted. You can also modify the file produced in this step and then use it as input to the script in the next step.
-
To run the script in default mode, enter the following line in your Command Prompt window:
deleteInactiveDFs.cmd -Dapriori.user=username -Dapriori.password=password
Running in this configuration will delete all inactive Digital Factories
To run the script and specify which inactive Digital Factories you want to delete, enter the following line in your Command Prompt window:
deleteInactiveDFs.cmd -DdeletionList="file pathname" -Dapriori.user=username ‑Dapriori.password=password
Here, file pathname is the full pathname of a .csv file that lists the Digital Factories to be deleted, for example, C:\my_df_info\inactive_dfs.csv. You can use the .csv file created in step 2, above, modified so that it lists only the Digital Factories that you want to delete.
Note that Digital Factories must be identified by name and revision, for example, aPriori USA (aP2026R1_SP00_F00_(2023-09)).