On Mon, 2012-03-26 at 15:50 +0100, Nick Hall wrote:
On 26/03/12 10:50, Tony Gordon wrote:
I have used tags in my database to differentiate different branches of my family tree. Somehow I now have a duplicate of each tag in the 'organise tags' list.
This should not be possible.  Do you know how this happened?
Only one of each shows when I click on the 'tagged selected rows' icon in the person view. But if I choose 'edit the tag list' in the person editor the duplicates show, with only one of the duplicates ticked. In the person filter editor, the duplicates also show. I have tried exporting and importing into a new family tree but that doesn't help.
Each tag has a unique internal id, a name and a colour.  If two tags somehow get the same name (which is a bug) then the code should still work but be confusing.  I'd have to look at the code, but it is quite possible that some menus would remove duplicate names.
How can I get rid of the duplicates without risking removing the wrong one and losing a tag that could be on a few thousand people?
You can rename a tag in the Tag Organiser.  Rename some tags so that the names are unique.  Then remove the unwanted tags.  Finally, rename the any tags back that have the wrong name.
Let me know if you have any problems.

Nick.

Nick

I have no idea how or when this happened so cannot help there. I looked at the exported xml file and each tag has its own tag handle and priority but the name and color were common for each duplicate.

I cleaned it up by:
adding a suffix '-1' or '-2' to the duplicate tag names
using the tag filter on the filter side bar to select those tagged '-2' for each tag in turn
removing the '-2' tag and adding the '-1' tag (fortunately there were not too many to change)
removing the tags with the suffix '-2' in the tag organizer
renaming the '-1' tags back to the original.

Tony