Created 09-27-2018 06:34 AM
How do I delete an Atlas tag which is associated with entities those are already deleted?
I found that I couldn't delete an Atlas tag named "mytag" and when I tried to delete that tag I saw "Given type mytag has references". However, "mytag" was not associated with any entities. Then I noticed "Show historical entities" checkbox and I checked the checkbox, then an entity already deleted appeared. I thought I could delete "mytag" after deleting the association between "mytag" and that entity, but I couldn't find the way to remove that association.
Created 09-27-2018 06:33 PM
The tag associated to the deleted entity can't be disassociated and hence can't be deleted.
Created 09-28-2018 02:48 AM
Thanks @Sharmadha Sainath
Created 12-21-2019 06:33 AM
You need to find the parent that has the association and delete the references.
Example:
I have a hive table with a column that is SSN and it had two tags associated to it. Even after the association was removed it still contains the history. When you delete you get an error message. Given type {TagName} has references.
In this case I know I have a hive_column that had this reference and I need to find the proper GUID in order to delete this reference and get this test setup out of my UI.
First I do a search for these items above in the Atlas UI.
Check the option for Show historical entities in the event yours has been deleted.
The information is displayed in the UI and this is the one I am after.
Next I will use the developer tools in chrome and generally I clear out any of the history to help reduce any confusion as to what I am looking for.
Next click on ssn or your entity that was associated to a classification.
The url is in the panel for the get request, and the GUID in the URL is what you are after.
Delete the classification from the GUID.
curl -iv -u tkreutzer \
Now you can delete the Classification from the UI, barring there are no other associations. If so, rinse and repeat for each hive column.
I will probably try to figure out a way to do this via REST with Python later in a way that finds all associated GUID's for us.
Hope this help...
Cheers