All PDF File Attachments Turned into Web File Links after an Old Sync

I've been working with Zotero on a new computer for about a month, and then activated the sync to my online account that I created with my old computer. I have quite a few files, and I did not want all of the PDFs stored online, so my online account only has the links. However, when I activated the sync on this local computer, all physical pdf attachments turned into the web linked files.

I checked my Zotero/storage directory, and the pdfs are still stored in that directory. How do I get those physical pdfs attached to each library item on my desktop application with out manually going in and re-attaching each file?
  • However, when I activated the sync on this local computer, all physical pdf attachments turned into the web linked files.
    No, I promise you this didn't happen. You're looking at different items or are confused in some other way.

    Can you provide a screenshot of what you're referring to?
  • edited March 4, 2025
    I did not want all of the PDFs stored online, so my online account only has the links
    I mean, I don't know what you mean by this. If you actually deleted attachment items online, then those would've been deleted locally when you synced.

    Note that you're at your file-storage quota, so any files you added on another computer wouldn't be synced to this computer unless you transferred the data directory manually.
  • I apologize for being unclear. I'm not sure I know what has happened and how Zotero syncing works. I am providing screen shots to help the narrative:

    In the following screen shot, just last week, all of these library items indicated that a physical PDF is attached under the attachment column (the rightmost column). Now, those pdf icons are not there. If you look specifically at the Niziol et al. attachment (highlighted on the screen), you can see that the icon indicates that only a web link is attached.

    https://s3.amazonaws.com/zotero.org/images/forums/u15425529/balkmdgngam6yypjj3c3.png

    Now, entering my Zotero directory, I can confirm that the highlighted item is, in fact, the PDF that should be attached under the Niziol et al. item.

    https://s3.amazonaws.com/zotero.org/images/forums/u15425529/wdwr5dx8uxcm05omyote.png

    I could just go in and re-attach this pdf to the library item, but I don't want to do that for the 100s of files missing their pdf location. Does that make more sense?
  • edited March 4, 2025
    Syncing didn't do that. It looks like you used export/import, and did so without files, so all attachments were converted to links. You can see that all those items have a Date Added around the same time.

    Assuming you have the original data somewhere, you should sort the library by Date Added and just delete that whole set of items.

    Unless you did something outside of Zotero, the file in 'storage' would have an associated item in your library. You can paste '6LREVJIJ' (or any of the other folder names) into the Zotero search bar in All Fields & Tags mode to see it.

    If you still have the old computer, you should do a proper transfer, either by adding a storage plan so that all files can sync or by copying the data directory.

    Don't re-attach anything manually.
  • Well, I guess I can't confirm that the sync did it. However, I know for a fact that all of these items were imported properly, as I had just accessed some of these PDFs before the sync, as soon as three days ago.

    So, if I delete all items that 1.) exist on my previous computer and 2.) don't have a pdf attachment, I should be able to merge with the newer items on this current computer without issue?
  • edited March 4, 2025
    Right, but I can confirm that the sync didn't do it — I wrote the sync code.

    This is an export/import. These are not the same items that you were using before — they're duplicates that you created when you imported. Again, just look at the timestamps. These items literally did not exist in your Zotero library before February 3.

    If you're going to post here, you're going to have to trust that we know what we're talking about.

    You can scroll further down in the list, sorted by Date Added, to see all the items in your library from before the import, dating back years.
  • edited March 4, 2025
    E.g., the item in your screenshot, "Winter Weather Forecasting throughout the Eastern United States. Part IV: Lake Effect Snow", exists twice in your library — once with a Date Added of October 2024 and another with a Date Added of February 3, 2025.

    The folder you show, 6LREVJIJ, is just a standalone attachment added to your library in March 2024. It doesn't have a parent item and (obviously) can't have anything to do with items that you created via an import in February 2025.
  • To be clear, if these items appeared when you synced, it's because you created them (via an import) on another computer, so when you synced this computer they were pulled down with the rest of your library. One way or another, you created them via an import on February 3. I'd guess that they're all duplicates and you should just delete them all, but you'd have to look more closely and figure out what exactly you did with your library. In any case, any items you actually had on this computer from before the sync would still be there, assuming you hadn't synced this computer previously and deleted the items elsewhere.
  • I trust you. I trust your knowledge of sync. Please understand I'm not implying anything about your knowledge of the process. I'm just confused and upset I abruptly lost (or thought I lost) all of the pdfs associated with the files in the past two days.

    But your latest additions to this thread are helpful! Ok. So, I did incorrectly import all items when I first got this computer (around Feb. 3, obviously). But, after reading the correct way to do it, I promptly deleted the Zotero Storage on the new computer, and imported everything correctly before opening Zotero. (Your latest post confirms this)

    I do not have two Niziol et al. items on my desktop application (only the Feb. 3 one). I do not have any duplicates of the Feb. 3 items. I'm assuming you see my two Niziol et al. items on my online library. How do I revert and/or re-sync my desktop applications to ensure I get the old, previously existing items?
  • It's syncing — you have all the same items. They're just in your trash. Undelete them, and then delete the items from February 3 instead.
  • Oh my goodness! They are all in the trash! I can't believe I had them the whole time in the trash.

    Ok! Ok I'm grasping what happened now. I think I can manage from here.

    Thank you for taking the time to look at this problem.
  • Oh boy. Except I'm realizing when I restore the items from the trash, their organization is not stored. So I have to go back through my 1200 items and reorganize into their different collections again, huh.

    I will reiterate, this is ultimately my fault for doing an incorrect import. But it is unfortunate that this happened simply because I synced at the wrong times. Thank you again for your help.
  • Items in the trash remain in their original collections. If that's not the case, you deleted the collections as well. (In Zotero 7, deleted collections are moved to the trash. In Zotero 6, deleted collections would have have been removed permanently.)
    But it is unfortunate that this happened simply because I synced at the wrong times.
    I don't know what you mean by this, but it sounds like you're still misunderstanding something. The time that you synced makes absolutely no difference — all it's doing is syncing changes you made on each device.
  • Note that you can merge items in the Duplicate Items view, and the merged items will remain in any collections that any of the items from each set were in.

    Zotero currently only lets you merge items one set at a time, though. I believe there are plugins that will let you choose all older or all newer items.
  • Ok. Yes. I think it was a series of syncing mistakes on my part (and no fault with the syncing system).

    When I restore the collections from the Trash to the library, the collections are returned as empty folders.

    However, to solve my organization issue, If I merge the duplicate items in Zotero's Duplicates folder, the organization is retained. So that's helpful too.
  • edited March 4, 2025
    We can't vouch for it, but I think this will let you bulk merge and choose all old or new items: https://github.com/ChenglongMa/zoplicate
Sign In or Register to comment.