AnsweredAssumed Answered

Workgroups to PDM Standard: a plan for data migration

Question asked by Matthew Wypych on Nov 3, 2017
Latest reply on Aug 20, 2018 by Alex Waddell

This post describes the method and tools by which I am migrating data from the Workgroups PDM to PDM Standard. I haven't found a discussion on the actual process so this is a conversation starter that will hopefully refine the process.


The starting point:

  • All of the files are stored in Workgroups PDM
  • All users work from a single directory called c:\vault
  • Current Workgroups vault includes a range of projects and assemblies/drawings maybe linked through multiple projects
  • Access to Workgroups vault files is through Soldiworks i.e. not through direct server access
  • Migration is to PDM Standard not Enterprise
  • The new PDM Standard vault has a single state work flow
  • Revisions are managed at the configuration level and hence not at all in PDM Standard


The target:

  • Reproduce the existing project structure as a directory structure
  • Only move the latest rev's
  • Maintain all assembly/drawing links
  • Keep any manual processes to a minimum (or at least make them as easy as possible)


The main challenge in the process is keeping the internal file links active as the files are migrated. Because of using a single directory for the Workgroups PDM vault (a recommended practice) all of the internal links are to the c:\vault directory and do not reflect the project structure. To maintain the correct links all of the part/assembly/drawing files must be moved in a single move operation. The trick is that once all of the files have been checked in they must be moved using windows explorer or Solidworks explorer. Batch file command line moves do not maintain the links.


Here's the process that was followed to achieve this:

1 Export current vault structure

To be able to sort the files into the directories we first need to get a record of which project each file is stored in in the Workgroups vault. This can be done using the advanced search within Workgroups using a criteria similar to “Document is not empty” OR “Document is empty”. This should collect all files within the vault and can be output to a tab separated text file and dropped into Excel for post processing.


Note, that some of the file descriptions seemed to cause errors in generating the tab separated variable file and needed to be manually cleaned up. The errors present themselves as consecutive lines with the same description displaced by several columns. Repeated cells were deleted.


1.2 Generate a Workgroups to Standard vault map

The data exported above has the file name, type of file and the project. This data can be manipulated in Excel to determine where every file in the Workgroups vault will end up in the PDM Standard vault. This means making all those decisions about file locations and structure before checking files into the new vault.


The map can be used to create two useful files. The first is a list of all the directories required in the new vault. This can be passed to a simple batch file for generating all the directories in the new vault (See CreateDir.bat and DirectoryList.txt attached. Note: Directories need to be checked in to be added to the vault and any folder card data needs to be added manually). The second useful file is a list of the file names and the destination folder in the new vault. The use of this file will be explained below.


1.3 Get files from Workgroups

The next step is to download all of the files from Workgroups into an empty working directory. Either empty the current Workgroups directory or create a new directory and select it from the Workgroup options. Expand all of the projects and assemblies either using the mouse and clicking on the [+] on each project/assembly or using the up/down/right arrow keys. This can be tedious for large vaults so a macro to automate the process makes quick work of it (see attached ArrowMacro.swp - edit the macro to change the number of loops, create a macro button, select the top of the tree in the Workgroups Vault and press the macro button).  Select the desired components and then right-click and select open/check out. Unselect Open now. Continue to get a local copy of every file in the Vault. Note: This may need to be done in a couple of steps. Windows only supports 10,000 GDI objects returning the full list on our file set caused Solidworks to crash.


1.4 Mark the files with target directory

Once the files are in the PDM Standard vault they can only be moved through windows explorer otherwise the file links break. A system that could automatically sort the files once they were in the vault would be ideal. However, because of the interface and lack of scripting options in PDM Standard the easiest approach is to simply mark each file with the target directory before shifting them into the vault and then manually distribute them to the appropriate directories. To make this manual process as easy as possible a variable was added to the PDM Standard vault called Workgroups Dir.


Each file can be marked with it's target directory using the Solidworks Document Manager and a visual basic script. An example created in Visual Studi Express is attached. (See Note: this is provided as an example only. Anyone who wants to use a similar script will need to obtain a Solidworks Document Manager license and consult the Solidworks Document Manager documentation.) This property is then mapped as a variable created in the PDM Standard Vault. The upshot of all of this is that once the files are in the PDM Standard Vault they can be sorted by the target directory and then dragged in groups to their final destinations.


1.5 Move files to the PDM Standard vault

Drag and drop the entire Workgroups vault directory into the PDM Vault. All Solidworks files must be dragged in a single operation to maintain the correct file links. Then the files must be immediately checked in. If files are opened before check in the links may corrupt.

1.6 Redistribute the files

Now that the files are in the vault with the correct links they may be dragged into the destination directory and the integrity of the links will be maintained. Directory by directory, based on the Workgroups Directory variable, drag each group of files into the destination directory.

1.7 Update the files with the File Version Upgrade tool

Once the files are in the vault it is important to upgrade all of the files to the latest version of Solidworks. This helps limit incompatibilites that creep into the Soldiworks format over the years. Look for File Version Upgrade tool under swpdmclient\Support in your install files.


My questions:

  • Does anyone know how to automate the sorting of the files in the PDM Standard Vault based on either the exported file map text file or the vault variable?
  • Is there a way to automate the entry of descriptions for the folders?
  • Is there a better way to do any of this?