Lightroom Classic: A deleted keyword refuses to go away.

  • 1
  • Problem
  • Updated 3 months ago
  • Solved
  • (Edited)
A deleted keyword refuses to go away. I am now on the latest 9.2 version of Lightroom classic. There is a keyword "Barrington" that I have deleted quite some time back but it refuses to disappear. It is no longer in the keyword list and cannot be found using the search. I type in a new keyword "Cherry Blossom" and along with this "Barrington" shows up in the Keyword tags. It does not export but it showing up in the tags with a number of arbitrary keywords is frustrating. This is not in the entered keywords hierarchy nor as its synonym. I just can't seem to get rid of it. has anyone had this issue or has a solution. This issue has persisted over quite a few updates. Every update I had hoped it would get fixed but sadly it persists.

Below is a screen shot. I just entered the keyword "Cherry blossoms" and "Barrington" shows up and is not in the keyword list when searched for
Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
  • Frustrated

Posted 3 months ago

  • 1
Photo of John R. Ellis

John R. Ellis, Champion

  • 5123 Posts
  • 1452 Reply Likes
If you do Metadata > Export Keywords, does it show up in the exported text file?  If it does, that might give more clues to the inconsistency and how you might get rid of it.
Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
No it does not. The exported text file has all the other keywords but not "Barrington"
Photo of John R. Ellis

John R. Ellis, Champion

  • 5123 Posts
  • 1452 Reply Likes
Another investigative step that might shed further light:

1. Download the Show Catalog Metadata plugin from here:
https://www.dropbox.com/s/jxljket1zpymase/showmetadata.1.4.zip?dl=0

Install it following the directions for any of my other plugins.

2. Select a photo assigned the bogus keyword and do File > Plug-in Extras > Show Catalog Metadata > Show.  In the window that pops open, scroll to the line that says "keywords = {". It should look something like this:



3. Copy and paste here the "keywords = {" line and the following indented numbered lines.

Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
Thank you so much John for trying to help me out. I did what you said and I am attaching a screenshot of the window

Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
Here is another file with more keywords and the unwanted keyword shows up again

Photo of John R. Ellis

John R. Ellis, Champion

  • 5123 Posts
  • 1452 Reply Likes
That's even more interesting. The plugin shows just one keyword assigned to the photo, "Cherry blossoms", and it's a top-level keyword.   No sign of "Barrington".

Please do this: In the Keywording panel, change Keyword Tags to Enter Keywords.  Post a screenshot of the Keywording panel.
Photo of John R. Ellis

John R. Ellis, Champion

  • 5123 Posts
  • 1452 Reply Likes
That second example is more curious: Show Catalog Metadata shows the photo assigned a top-level keyword "Wood", but the Keywording panel shows it as Wood < Barrington, meaning the Keywording panel thinks that the keyword Wood has a parent Barrington.
Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
Correct. And The cherry blossom shot when changing the keyword tag to Enter Keywords, "Barrington" does not show up. Here is the screen shot
Photo of Philippe Coudé du Foresto

Philippe Coudé du Foresto

  • 97 Posts
  • 34 Reply Likes
I saw this problem of a ghost keyword twice, whithout knowing what introduced it. I research and found the following:
The keywords are stored in hierachical table called AgLibraryKeyword. The first record of this table is the parent of all records, it is not supposed to contain a keyword and its fields lc-name and name are set to null. It doesn't appear in the keyword list.
For some reason, in 2 cases, fields lc_name and name of this first record were set to a text value, resulting to this record to be displayed as a parent keyword like shown here.
In your case, I'm sure the 2 fields lc_name and name of this first record is set to "Barrington", resulting in this ghost keyword shown.
I fixed the problem by manually changing the value of the 2 fields lc_name and name of this first record to null.

(Edited)
Photo of John R. Ellis

John R. Ellis, Champion

  • 5123 Posts
  • 1452 Reply Likes
Philippe's description sounds like it could account for what you're seeing. I think if you keep the Keyword Tags set to Enter Keywords, you could ignore the bug without any ill consequences.  But if you want to edit the catalog database, you'll need a program like DB Browser for SQLite (there are a number you could use).  And I can't really recommend it unless you have at least some previous technical familiarity with SQL databases.  And and if you do try this, be sure to make a backup copy of your .lrcat database first!
Photo of Philippe Coudé du Foresto

Philippe Coudé du Foresto

  • 97 Posts
  • 34 Reply Likes
I second John's comment of not trying to fix it yourself if you're not very familiar with database structure, and having a backup if you do.
Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
Unfortunately "Barrington" shows up often even when keyword tag is set to Enter keywords. (image attached). I contribute to stock hence work with keywords quite a bit and it is really annoying to see an unwanted keyword show up again & again. But thanks for your suggestions. I really appreciate it. I am not familiar with SQL databases but am going to take my son's help (he is a student of computer science) - & hopefully we will sort this out

Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
Yay! Problem solved! Thank you Philippe & John. I did not understand much of what Philippe had suggested but apparently my son did & he followed both of your advice & - no more "Barrington". Thank you once again
Photo of John R. Ellis

John R. Ellis, Champion

  • 5123 Posts
  • 1452 Reply Likes
Glad you got it resolved.  It's definitely an infrequently occurring bug in at least some versions of LR, but it's very unlikely to get fixed (in my opinion).
Photo of Manpreet Sokhi

Manpreet Sokhi

  • 20 Posts
  • 2 Reply Likes
At least I know what to do if it happens again - thanks to both of you. Have a great day & be safe