Database Reference
In-Depth Information
Click
Next
, select the v2 data model as the source model and select the v3 data
model as the target model.
Name the new file
UnCloudNotesMappingModel_v2_to_v3
. The file naming
convention I typically use is the data model name along with the source version and
destination version. As an application collects more and more mapping models over
time, this file naming convention makes it easier to distinguish between files and
the order in which they have changed over time.
Open
UnCloudNotesMappingModel_v2_to_v3.xcmappingmodel
. Luckily, the
mapping model doesn't start completely from scratch—Xcode examines the source
and target models and infers as much as it can, so you're starting out with a
mapping model that consists of the basics.
Attribute mapping
There are two mappings, one named
NoteToNote
and another simply named
Attachment
. NoteToNote describes how to migrate the v2 Note entity to the v3
Note entity.
Select
NoteToNote
and you'll see two sections:
Attribute Mappings
and
Relationship Mappings
.