₹0.00
0

How to Find Duplicate File Names in a SOLIDWORKS PDM Vault

Duplicate file names cause wrong references and failed check-ins. Find every duplicate in your SOLIDWORKS PDM vault with one PDMShell search.
How to Find Duplicate File Names in a SOLIDWORKS PDM Vault
Picture of Amen Jlili

Amen Jlili

Amen Jlili is the founder and technical director of Blue Byte Systems Inc., a software company in Vancouver, Canada, specializing in automating SOLIDWORKS and PDM.

Duplicate file names are one of the most common causes of trouble in a SOLIDWORKS PDM vault. An assembly opens the wrong bracket, a check-in fails because the name is already used, or two engineers edit what they think is the same part. The longer a vault lives, the more of them it collects.

The manual way

PDM’s search tool can find files by name, but it does not tell you which names appear more than once. Most admins end up exporting search results to Excel and sorting them, which works once and is painful to repeat.

The faster way: one search command

PDMShell’s search command can group results by name and keep only the names that appear more than once. Change to the folder you want to check, then run:

cd \Projects
search -search "Name=%.sld%;Recursive=true;DuplicatedBy=Name" -columns "FileDate,Hash,Revision"

This lists every SOLIDWORKS file below the current folder whose name is used more than once, with its date, hash and revision side by side.

  • % is a SQL wildcard, so %.sld% matches parts, assemblies and drawings.
  • DuplicatedBy=Name keeps only the names that appear more than once.
  • FileDate, Version, State and Hash are special columns that are not on the data card. Hash tells true copies apart from different files that just share a name.
  • Add -csv duplicates.csv to save the result for review in Excel.

Tips

  • Hash needs the file to be in your local cache. Get the files first if you want to compare contents.
  • Search also supports SortBy, SortOrder and GroupBy, so you can sort by date to see which copy is newest.
  • Once you know which copies to keep, the CSV can drive a bulk rename or move with renamefromsource and movefromsource.

Try it on your own vault

Start a free 7-day trial of PDMShell, see plans and pricing, or read the search command reference. Questions? Book a short call with our team.

Need this adapted to your workflow?

We build custom SOLIDWORKS macros, add-ins and PDM automation.

Picture of Amen Jlili

Amen Jlili

Amen Jlili is the founder and technical director of Blue Byte Systems Inc., a software company in Vancouver, Canada, specializing in automating SOLIDWORKS and PDM.

Leave a Comment

0
0
Your Cart
Your cart is emptyReturn to Shop