![](/images/new-backgrounds/1214202/214202363x1.webp)
Mapping objects in an XML model
In the Mapping page, you can use the following tools to select a data source for the current element:
Tool | Description |
| Adds a mapping between the current element and an existing data |
| source. The first time you define a mapping for an element, the |
| Mapping for dropdown listbox is empty. You have to click the Add a |
| Mapping for a Data Source tool before you can map the elements to |
| tables in the data source |
|
|
| Deletes the mapping for the data source | |||
|
|
| Edits properties of the selected data source | |||
Element Sources | The Element Sources page allows you to associate one or several tables in the | |||||
page | data source to the current element. | |||||
| You can use the Add Objects tool to select tables from the PDMs opened in | |||||
| the current workspace. |
|
|
| ||
Attributes Mapping | The Attributes Mapping page allows you to define the mapping between | |||||
page | columns in the source tables and attributes in the current element. | |||||
| Tool |
| Tooltip |
| Description | |
|
|
| ||||
|
|
|
|
|
|
|
|
|
| Add Mapping |
| To select the attributes in the current element | |
|
|
|
|
| that will be mapped to columns in the source | |
|
|
|
|
| table. Once you have selected the attributes, | |
|
|
|
|
| you can use the dropdown listbox in the | |
|
|
|
|
| Mapped to column to select corresponding | |
|
|
|
|
| columns in the source table | |
|
|
| Create from Sources |
| To copy columns from the tables in the data | |
|
|
|
|
| source to the current element | |
|
|
| Generate Mapping |
| To automatically generate a mapping between | |
|
|
|
|
| columns and attributes with same name or | |
|
|
|
|
| code in the data source and the current model | |
|
|
|
|
|
|
|
Mapping complex types
You can map complex types to PDM objects.
Once the abstract data types are identified and mapped with the complex types, you can define mappings between abstract data type attributes and complex type attributes.
170 | PowerDesigner |