Batch renaming with ZotFile does not work

Hey all,

I have imported my whole library (930 documents) from Mendeley to Zotero. The first step worked fine, and all documents are there, including all folders.
All files are in Zotero as linked files, refering to the original Mendeley folder. I want to move all PDFs inside the Zotero data base, which I have set up with WebDAV.

I can right-click a file and select Manage Attachments -> Rename Attachments, which renames the file and stores it in the Zotero data base. However, when I select multiple files and do this, only the first file gets renamed and moved, and nothing happens to the others.

I hope Zotero is able to batch import like this, because I do not feel like doing it manually for nearly a thousand files. Please help.
  • All files are in Zotero as linked files, refering to the original Mendeley folder.
    Which folder do you mean? Files that were in the Downloaded folder in Mendeley should've been imported as stored files. Only files that were elsewhere on your hard drive (as the equivalent of linked files in Mendeley) should've been imported as linked files.
  • edited June 29, 2018
    I mean the folder Mendeley stores all its PDFs in. Those PDFs are linked files in Zotero, not actually imported. I must say my Mendeley directory is custom, but Mendeley at least knows that.
    Edit: same thing happens when Mendeley is at the default location.
  • So to clarify, in Mendeley you can have files in the "Downloaded" folder within the data directory or elsewhere on your hard drive. When they're in the latter, Zotero imports them as linked files, because it assumes you want to keep them in the original location and keep your existing folder structure.

    If you no longer want to do that, and want to store the files within the Zotero data directory and have Zotero manage and sync them, ZotFile may be able to convert them for you. I don't know the details of that, but someone else should be able to help. I just wanted to make sure that that's what you wanted to do and to explain the behavior you're seeing during the import.
  • I assume what you call the "Downloaded" folder is what Mendeley stores all files in if you use the "Organize my files" utility (a single folder Mendeley by default calls "Mendeley Desktop"). I use that, so all my documents are in a single folder on the hard drive.
    When I import from Mendeley in Zotero, all files are linked files, and "Show File" directs me to the "Mendeley Desktop" folder. Only when I use Zotero's "Rename Attachment" function (from ZotFile), the actual files get imported into Zotero's data base.

    So what you are saying does not happen in my Zotero.
  • No, "Downloaded" is the literal name of a folder within your Mendeley data directory. It's where files go if you don't use "Organize my files".

    If you choose to store your files elsewhere on disk — outside the data directory — Zotero imports them as linked files, because that's the closest equivalent in Zotero.
  • Not only did that not work, it also showed me Mendeley is really messed up. Turns out since v1.19, the data base is encrypted, so I had to downgrade to v1.18, pull my library from online, then import it into Zotero.
    Still, Zotero creates links to the original Mendeley locations (so, this time, inside the "Downloaded" folder).

    And if I use ZotFile's rename function on multiple files, it still only renames the first one. So what you were saying (If Mendeley files are stored in "Downloaded", Zotero imports the PDFs to its own database), does not happen in my case.
  • edited June 30, 2018
    Did you start from scratch (by deleting your Zotero data directory) or did you reimport into your existing library?

    If the former, what’s the full path to your Mendeley data directory? (You can X out your username.)
  • I tried going from scratch now, and still the same. Mendeley data directory: "C:\Users\user\AppData\Local\Mendeley Ltd\Mendeley Desktop\Downloaded"
  • Could you generate a Debug ID for running the import from scratch? With that path it should definitely be importing those files as stored files.
  • I managed to do that. The debug ID is D1367950961. The Zotero data base was empty before this import.
  • Ah, so, it's actually not that path in your case — it's "Mendeley Ltd.", with a period, which might be a path used in older versions of Mendeley. If you try from scratch again with the Zotero beta (or rename "Mendeley Ltd." to "Mendeley Ltd" with the current release version), it should properly store those rather than linking to them.

    (Just to confirm, when you go to do the import with that folder named as it is now, you only get a file option and need to go select the Mendeley database manually, right? You don't get a "Mendeley" option when you first go to File → "Import…"?)
  • edited July 2, 2018
    Yes! Using Zotero Beta did the trick. ZotFile is now automatically renaming all the files during import (and moving them, I guess).

    Using the latest official build on a different computer with "Mendeley Ltd" without the dot did not. I do not know if the beta would work with a folder with the dot (Ltd.).
  • It's Zotero that's now storing (rather than linking) the files properly for you — that's not ZotFile.

    We'd have to look at a Debug ID from the other computer to debug that one, but to clarify, you don't want to import on multiple computers if you're planning to use Zotero sync. You'll just end up with duplicates of everything that way.
  • I understand that I want to do the import on but one computer. It's just that I started it on my home computer my tried it on my work computer yesterday. In the end, I cancelled the import on my work computer and set it up on my home computer, by using Mendeley 1.18 and Zotero Beta. Strangely, the Mendeley folder was already named without the dot (but it did not work with the latest official build).
    I cleaned my entire Zotero library before importing, and, after import, set up sync with my own WebDAV directory. That worked out great, so I am now fully moved over to Zotero.
    Thank you so much for your help. I could not have done it without you.
Sign In or Register to comment.