Remove all tags

Hello,

most of the items in my library got tags that were downloaded with the item, but they don't meet my needs. So, I would like to get rid of all tags for all items. Is there an easy way to do it? I only managed to delete tag by tag of single items and that is very cumbersome.

Thanks,

Sebastian
«1345
  • There's currently no easy way to remove all tags from all items, but you can hide them by deselecting "Show automatic tags" in the tag selector menu, and you can turn off the feature in the preferences that automatically attaches tags to items downloaded using translators.
  • Hello,

    Where exactly is the tag selector menu?

    Thanks,
    Amber
  • Hello again,

    Okay, I had the long-tags-no-scroll-wheel problem because a bunch of automatic tags were added before I knew about changing that setting in the Preferences (it would be nice if this were not the default setting). So I couldn't see the little menu next to the filter box. I had to open Firefox across two screens in order to make the tag window wide enough. However, unchecking "show automatic tags" has not solved my problem, as all of these heinously long tags are still being shown. I am using Firefox 3.0.1 and Zotero 1.0.7 on an intel MacBook OS 10.4.11.

    Is there something else I can fiddle with to hide the automatic tags? For now I am deleting tags individually.

    Thanks,
    Amber
  • JM
    edited November 26, 2008
    I have the same problem Amber does.
    1) Trying to delete hundreds of auto-generated tags takes forever. How about the ability to select and delete multiple tags at once? Or a tag editor as a preferences tab?

    2) Can't seem to hide the auto-tags. I have the "show automatic" button unchecked, but I still see all of the imported keywords and subject headings. I'm using Firefox 2.0.0.8, Zotero 1.0.7, on an intel MacBook OS 10.5.5.

    Thanks,
    JM
  • JM
    edited November 29, 2008
    Update:

    Turns out what I thought were auto-generated tags in Zotero were actually keywords auto-generated by EndNote when I imported items from my library website in the first place. Those keywords don't disappear when you turn off "Show automatic" in the tags display window.

    Deleting these imported keywords is pain-staking in Zotero. The "Terms List" in Endnote looks like an option for global term editing. If that worked I could just edit keywords globally in Endnote, then reimport. BUT changes made in the EndNote Term List don't populate to your records. Arghhh.

    Only option I've found so far is to delete ALL of my Endnote keywords using EndNote's "Change Fields" command to replace all of my keyword text with nothing. This seems like the nuclear option, but it might be better since adding keywords to multiple entries in Zotero is so easy (although slow).

    Anyone know how I can batch or globally edit a few hundred keywords in Endnote or Zotero without consuming several weeks of my life?

    Thanks for any input!
    An almost thrilled convert...
  • Hi there,

    Sort of same problem as I would like to have a tag editor as well. I have add tags manually only to find I have misspelled one or another and would like to remove them.

    RPB
  • rpbaar01: You can already rename and delete tags globally by right-clicking on them in the tag selector (in the bottom-left corner of the Zotero pane). Renaming to an existing tag will merge the two tags.
  • Again, thanks Dan you're a wunderkind :-)

    Rich
  • Please allow the deletion of multiple tags at a time. I have hundreds of worthless tags that I want to delete!
  • I would like to second that. Is automatic tag-downloading after zotero installation on by default? A warning would be desirable in that case.

    At first automatic tagging seems handy, but some sites add literally dozens of tags to one article/website. These have to be removed one by one...
  • This would perhaps be a bit more tolerable, if it didn't take about 5-10 seconds to delete a single tag (at list with 12,000+ entries)! If I have hundreds or thousands of tags to delete, I'm looking at dozens or scores of hours! No thanks!
  • edited December 9, 2020
    [Developer's Note, 2020: Making changes directly to the Zotero database is strongly discouraged, and absolutely shouldn't be done if you're using Zotero syncing. — D.S]

    I had to delete my tags (almost all of which were automatically added and so not useful to me) in order to sync Zotero with the cloud. I did it by editing Zotero's SQLite database directly.

    Please note, I do NOT recommend this unless (1) you're sure that you don't want the tags, (2) you're comfortable working with databases, and (3) you've backed up your Zotero library. Doing this definitely voids the warranty, metaphorically speaking.

    Here's how I did it:

    1. Back up your Zotero library. Seriously. I backed mine up by copying the Zotero directory and by exporting my entire library as a Zotero RDF.

    2. Quit Firefox. It's not a good idea to try this with Firefox running.

    3. Open the Zotero database in an SQLite browser. This is the SQLite browser I used: http://sourceforge.net/projects/sqlitebrowser/. The database is contained in your Zotero directory, which you can find by going to Preferences > Advanced > Show data directory. The file is zotero.sqlite.

    4. In your SQLite browser of choice, go to where you can execute SQL commands. Execute the following two commands, making sure you get it exactly as below:

    delete from itemTags

    delete from tags

    5. Save the database.

    6. Open Firefox and Zotero. All your tags should be gone.

    As I said, only do this if you're absolutely sure.
  • edited February 25, 2009
    Worked perfectly. Thanks, Lincoln!
  • edited December 9, 2020
    [Developer's Note, 2020: Making changes directly to the Zotero database is strongly discouraged, and absolutely shouldn't be done if you're using Zotero syncing. — D.S]

    I was in the same situation but had already defined a lot of my own tags, so I wanted to delete ONLY the auto-generated tags. The following worked for me (2 separate sql commands):


    delete from itemTags where itemTags.tagID in (select
    tags.TagID from tags where tagType = 1)

    delete from tags where tagType = 1


    Back up the database before you do this!

    n.b. the "magic number" 1 - I assume this is a hard-coded constant for auto-generated tags but actually I came up with it by eyeballing the data, not the code. So if you're paranoid confirm with your own data.
  • Good to know. Thanks, Alex. Fortunately, I'm just getting started with Zotero so I had manually created very few tags so far. No big loss.
  • Hi,

    I've read this discussion with keen interest as I have the same problem--automatic imports of tags are messing up my tag library. From above, Dan Stillman wrote:
    "...you can turn off the feature in the preferences that automatically attaches tags to items downloaded using translators."

    I could not figure out how to do this. Could somebody please advise? I just want to stop the automatic tag imports from occurring, nothing more.

    Thanks!
  • Open the Zotero pane, click on the gear-icon, and select "Preferences...". In the Zotero preferences window, select the "General" tab on top, uncheck the option "Automatically tag items with keywords and subject headings" and click OK.
  • Thanks very much. I now see this option with the updated version. This is perfect. I'll use my newfound free time to sing to my neighbors.
  • in fact, these auto-generated giant tags make it impossible to migrate the library to the server!!! I am not sure I have time to delete the tags one-by-one!
  • Hi,
    I have come across this discussion as I am encountering the same problem as described above, i.e the tags in my library are too long for the sync option to work. Manually editing the offending tags is not an option as there are far too many. So, I tried Lmullen's and others suggestion to use an SQLite browser to edit my tag library. However, when I try to delete the offending tags using SQLite Expert Personal I receive the error message "Abort due to constraint violation". Does anybody have some advice/suggestion why this is and how it can be avoided? Any help very much appreciated.
  • Please create a function that allows you to select and delete multiple tags at once! I would really love to use tags (and to give up Endnote), but having a thousand (or more) useless tags imported from Endnote is a big problem. It takes about 10 seconds to delete just one tag.
  • One more vote to do something about these endless tags. There are over one thousand useless tags filling my database and preventing me from syncing with the server. I plan to try the direct database option above, but something safer and more automatic would really be great. Thanks.
  • +1
    This feature would be really needed and appreciated.
  • edited June 19, 2023
    [Developer's Note, 2020: Making changes directly to the Zotero database is strongly discouraged, and absolutely shouldn't be done if you're using Zotero syncing or ever want support here. — D.S]

    Hi, don't know if this helps anyone, but I managed to use lmullen and alexuw's suggestions to fix this.

    1. Downloaded sqlite browser for Mac. http://mac.softpedia.com/progDownload/SQLite-Database-Browser-Download-30549.html

    2. Browsed the "tags" table. There were a few tags I wanted to keep, and I found that my auto-generated tags were all coded either 1 or 0, and the tags I made myself were coded 0, so I re-coded the tags I wanted to keep to be type = 2, then:

    3. Ran alexuw's lines

    delete from itemTags where itemTags.tagID in (select
    tags.TagID from tags where type = 1)

    delete from tags where type = 1

    For both type = 0 and 1. Note that I tagType (see alexuw above) didn't work, so I changed command to just "type".

    4. I then recoded my surviving tags to be type = 0, and this seems to have done the trick. At least I haven't found database corruption yet (and I have no idea about sqLite, so hopefully this remains to be the case!).

    Cheers.
  • Thanks alexuw for your hint. Since i could not sync my database with the cloud and I did not want to get rid of all tags, only of tags exceeding 255 digits, i adapted your command:

    delete from itemTags where itemTags.tagID in ( select
    tags.TagID from tags where length(name) > 254)

    //new script

    delete from tags where length(name) > 254
  • Dan, any change in this? Trying to manage a group library, and it's a major PITA to try to deal with the mess of auto-tags we now have. I can't delete them even individually, nor apparently even change their names.
  • +1 for multiple record tag editing
  • Changes in column names:

    delete from itemTags where itemTags.tagID in (select
    tags.tagID from tags where type = 0)

    delete from tags where type = 0

    THIS DELETES ALL NON-AUTOMATIC TAGS. I.e. your own tags.
    ...Or some type of older tags, as I had a lot of tags with type 0, without having added them myself. Annoyingly, these don't get hidden if you uncheck 'Show automatic', so I guess a while ago auto tag adding didn't work exactly the same way it does now.
  • +1 for better tag management
Sign In or Register to comment.