๐ Edit author's aliases array
We want to modify the MongoDB schema so that each author's aliases are represented as an array of strings.
We want to move from:
authorAliases: [
{
"authorId": 1,
"alias": "Quevedo"
}
]
to:
aliases: [
"Quevedo"
]
- On the MongoDB diagram view, click on the
authors
collection. - On the relational mappings list on the right, click on the edit icon of
author_alias
embedded array mapping rule. - rename the array
authorAliases
intoaliases
. - In the list of fields, uncheck
authorId
. - In the mapping rule's advanced settings, Check
create array of primitive values
. - Click
Save and close
.
