Categorize terms¶
Terms in a glossary can also be organized in one (or many) categories.
Remember the glossary is the container, not the category
Remember that the glossary is what contains the term, not the category. Therefore a term must have a glossary, but is not required to have a category. Also, a term can (optionally) be organized in many categories, but can only exist in one glossary.
Category must exist before creating or updating the term
Remember: each category must already exist before you create or update a term that refers to the category.
During term creation¶
To categorize a term during its creation:
Categorize during creation | |
---|---|
1 2 3 4 5 6 7 |
|
- A name for the new term.
- The glossary in which to create the term.
- You can then add any number of categories using the
category()
builder method. In this example the term will be categorized in a category with a GUID ofdc4c0a08-a902-402b-bf24-cf935aecc343
... - ...in this example the term will also be categorized in a category with a
qualifiedName
given by theanotherCategoryQN
variable. - You need to build the object you've just defined.
- You then only need to
save()
1 the object to create it in Atlan.
Categorize during creation | |
---|---|
1 2 3 4 5 6 7 8 9 10 11 12 |
|
- A name for the new term.
- The glossary in which to create the term.
- You can then add any number of categories through the
categories
named argument. In this example the term will be categorized in a category with a GUID ofdc4c0a08-a902-402b-bf24-cf935aecc343
... - ...in this example the term will also be categorized in a category with a
qualified_name
given by theanother_category_qn
variable. - You then only need to
save()
1 the object to create it in Atlan.
POST /api/meta/entity/bulk | |
---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
|
- All assets must be wrapped in an
entities
array. - You must provide the exact type name for the term (case-sensitive), which for a term is
AtlasGlossaryTerm
. - You must provide the exact name of the term (case-sensitive).
- You must provide the exact name of the term (case-sensitive) as you want it to appear in the UI.
- You must provide an
anchor
relationship. - Within the
anchor
relationship you must provide the exact type name for a glossary:AtlasGlossary
. - Within the
anchor
relationship you must provide the GUID of the glossary the category should be created within. - When you want to place the term into one or more categories, you must provide the
categories
relationship. - Within a
categories
relationship, you must provide the exact type name for a category:AtlasGlossaryCategory
. - Within a
categories
relationship, you must provide either the GUID of the category (in this example)... - ...or the
qualifiedName
of the category, which itself must be further nested within auniqueAttributes
object.
Updating an existing term¶
To create a child category, the steps are very similar but you add in the reference to the parent category:
Update an existing term | |
---|---|
1 2 3 4 5 6 7 8 |
|
- The
qualifiedName
of the existing term. - The name of the existing term.
- The GUID of the glossary in which the term exists.
- You can then add any number of categories using the
category()
builder method. In this example the term will be categorized in a category with a GUID ofdc4c0a08-a902-402b-bf24-cf935aecc343
... - ...in this example the term will also be categorized in a category with a
qualifiedName
given by theanotherCategoryQN
variable. - You need to build the object you've just defined.
- You then only need to
save()
1 the object to update it in Atlan.
Update an existing term | |
---|---|
1 2 3 4 5 6 7 8 9 10 11 12 |
|
- The
qualified_name
of the existing term. - The name of the existing term.
- The GUID of the glossary in which the term exists.
- You can then add any number of categories using the
categories
property. In this example the term will be categorized in a category with a GUID ofdc4c0a08-a902-402b-bf24-cf935aecc343
... - ...in this example the term will also be categorized in a category with a
qualified_name
given by theanother_category_qn
variable. - You then only need to
save()
1 the object to update it in Atlan.
POST /api/meta/entity/bulk | |
---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
|
- All assets must be wrapped in an
entities
array. - You must provide the exact type name for the term (case-sensitive), which for a category is
AtlasGlossaryCategory
. - You must provide the exact name of the term (case-sensitive).
- You must provide the exact
qualifiedName
of the term (case-sensitive), as it already exists in Atlan. - You must provide an
anchor
relationship. - Within the
anchor
relationship you must provide the exact type name for a glossary:AtlasGlossary
. - Within the
anchor
relationship you must provide the GUID of the glossary the category should be created within. - When you want to place the term into one or more categories, you must provide the
categories
relationship. - Within a
categories
relationship, you must provide the exact type name for a category:AtlasGlossaryCategory
. - Within a
categories
relationship, you must provide either the GUID of the category (in this example)... - ...or the
qualifiedName
of the category, which itself must be further nested within auniqueAttributes
object.
-
Why no distinction between create and update? This has to do with how Atlan detects changes — see the Identifiers concept for a more detailed explanation. ↩↩↩↩