"File already exists" warning in Enterprise PDM but I can't find it in the vault!
The most likely reason for the warning “File already exist” would show when adding a file to a folder is that a file with the same name already exists in that folder, but the logged in user does not have sufficient permission to see the file. It is not possible to have two files with same name in same folder.
Example A – restricted state permission
1. Logged in user on Workstation2 has read and add permission to the folder, but only read access to workflow state “Waiting for approval”.
2. A file that is in “Under editing state” and has not yet been in the “Waiting for approval” state exists in the folder (a user with read access to the state can see it on Workstation1).
3. If the user tries to add another file with the same name to the folder, add will fail with “”File already exist”
Solidworks provides us with a couple of examples that explain the most likely scenarios and a query to help us investigate the file further.
Example B – users private state
1. User “Tor” on Workstation1 has added a file to a folder. The file will end up in user Tor’s “private state”. The private state is where files are placed when added, but not yet checked in and assigned a workflow. Note that files still in user’s private state will not show a state name in the state column.
2. User “Bastien” logs in on Workstation2 and browses to the folder. The file will not be visible since it is in Tor’s private state.
3. If Bastien tries to add a file with same name to the folder, add will fail with “File already exist”
Note: The “Admin” user login is the only user able to see files in other user’s private state.
– When troubleshooting this type of warning, make sure you assign “Admin” full permissions in all folders and workflow states. If Admin can see the file, but not the user, it is likely caused by the restricted user permission.
– If the file still cannot be found when logged in as Admin; the below “ShowFileInfo” query can help display information from the database about a specific filename.
–Query to list file details of specific file. Update with filename below.
p.Path + d.Filename as [File path],
WHEN S.StatusType = 3 then (W.Name + ‘.’ + S.Name)
‘<Private state – ‘ + (Select Username from Users where InitialStatusID = S.StatusID) + ‘>’
END as [Current State],
WHEN (d.LockProject != 2) then ‘Yes <‘ + (Select Username from Users where UserID = D.UserID) + ‘>’
END as [Checked out?],
CASE WHEN d.Shared > 1 then ‘Yes’ ELSE ” END as [Shared?],
CASE d.Deleted WHEN 1 then ‘Yes’ ELSE ” END as [Deleted?]
from Documents d
join DocumentsInProjects dp on d.DocumentID = dp.DocumentID
join Projects p on dp.ProjectID = p.ProjectID
join Status s on d.CurrentStatusID = s.StatusID
join Workflows w on s.WorkflowID = w.WorkflowID
Where d.ObjectTypeID = 1 and
d.Filename = ‘Part1.sldprt’ –<<< Update with filename to check
Order by [File path]
Reference: Solidworks Solution Id: S-054335