span8
span4
span8
span4
The first step in any Schema mapping process is to determine the desired output.Decide whether theSchemaMapperwill be mapping Feature Types and attributes,or adding new attributes to the destination schema (or a combination of these).Once the structure has been decided,an external lookup table can be created and connected to theSchemaMappertransformer within FME Workbench.
The lookup table can be stored in many different formats,including: comma-separated value files;spreadsheets (Excel or Google);or as tables in a database.Below is an example of a spreadsheet-based lookup table:
Notice that there are two columns and the first row contains headers.
Column Headers:are created by the user and should be named in a meaningful way as they will be referenced within the SchemaMapper transformer.These are also referred to as field names or attribute names.
Table Data:is defined by the source dataset or created by the user (when specifying destination schema).Data can be comprised of attribute names,attribute values and feature type names.
Column Pairs:Notice that the example above contains two columns.Since Schema Mapping is the act of connecting the source schema to the destination schema,there will be pairs of columns in the lookup table that define source and destination schemas within the transformer.For example,the lookup table below contains two columns: a source Feature Type column which is paired with a desired destination Feature Type column.
Another pairing type occurs when you have a source attribute name in one column paired with its attribute value in another.This pairing type is used for filtering and is discussed in parts3,4and5of the SchemaMapper tutorial.
Once the external lookup table has been created,the SchemaMapper transformer can be utilized.
Note:a simple lookup table can be generated from a source dataset which can function as a starting point for the mapping process.For more on this,please see the following article:Generating a Lookup Table from Source Data.
The SchemaMapper transformer has two components,a reader which is used to open the lookup table and an action dialog to define the schema mapping rules.The reader is straightforward and resembles the usual reader for text files or databases.
This image shows the SchemaMapper reading from a lookup table created in a .csv format:
This image shows the reader parameters for this specific lookup table.Notice that column headers are selected from the lookup table which define the source and destination feature types:
Using descriptive column headers will make actions easier to create and the 亚搏在线workflow easier to understand.
The action dialog is the second component of the SchemaMapper.This dialog is used to define rules for schema mapping using information stored within the lookup table.Specifically,field names from Line 1 of the lookup table have been recognized and tell the SchemaMapper how to take action.
Once an action is created,it will be displayed in the action dialog.Each SchemaMapper transformer can contain multiple actions.In the example below,the image contains a SchemaMapper which is set up to map both feature types and attributes:
Each subsequent section in this guide will showcase a specific function of the SchemaMapper transformer with an increase in complexity along the way.
SchemaMapper: Conditional Attribute Mapping
SchemaMapper: Feature Type Mapping
SchemaMapper: Conditional Feature Type Mapping
Dynamic 亚搏在线Workflows: Advanced Example - Modifying the Schema Feature
SchemaMapper: Attribute Mapping
Dynamic 亚搏在线Workflow Tutorial: Advanced Technique - Using the SchemaMapper
SchemaMapper: Advanced Schema Mapping
© 2019 亚搏在线Safe Software Inc |Legal