10 Dec 2007
08 May 2010
Link to this post
First, this isn't urgent (go ahead and take St. George's day off!) :)
I've found what I think is a bug with how Sitefinity handles uploading a document with a duplicate name...though I haven't tested all cases and other versions of Sitefinity. I'm using 3.7 SP3.
If you upload a document to a library (let's say a PDF), and then later upload a second one (with the exact same name), you end up with two different copies in the library. Because they both have the same name, you can only ever open one of them...whether it's the first or second one seems to vary.
When I run this in my dev environment SF initially creates a new document with the same name and "(1)" appended to it. But you can change it, and the SF doesn't care about the duplicate file names (obviously because it's using a unique identifier). And you can select either of the documents when you use a tool editor. But when you create a dynamic URL based on the [provider]GUID, you'll get the same URL for both. And only one of them will ever return.
If you use the "Re-upload" button (after clicking Edit on the item), then all works as expected--you upload a new version of the same document.
I think there should either be a duplicate file name check (and error message in the form field telling you it's a duplicate), or else upload and replace a previous version. The second case is a bit more dangerous, though, as the user might not expect their upload will replace a document. I'd favor the first case, preventing duplicate file names, since you can always use re-upload to update an existing document.
This is not urgent for me, as I've instructed our users to use the Re-upload button from the Edit screen, and only upload new documents using the Upload button, But in one case, I think the user was editing the name of the document, and didn't notice the duplication until afterward.
Is there some configuration where "allow duplicates" can be turned on or off?