Smart Mapping: Matching and Rule Generation

Ok, so you recently read a few posts about automated mapping, specifically Smart Mapping and you’re thinking to yourself, “Awesome!  I love it when computers do useful things for me and make my life easier… But what does Smart Mapping actually do?”  Well, the simple answer to that question is it does two things, matching and rule generation.  Now you’re thinking “Oh, right….  Well, what does THAT mean?”  Fear not, I will explain.

But before I do, it is important to understand that Smart Mapping is initiated from and runs in the EBI Ruleset Editor.  Those of you who are familiar with the EBI Ruleset Editor already know what rules are and their role in mapping.  Those of you who are not familiar with the EBI concept of rules and the Ruleset Editor may want to refer to Greg Inns’s scintillating blog “It’s all about the Model”.  In it, you’ll find explanations of what rules are and how EBI uses them to get data from source to target. Now on to the good stuff.  “Matching” refers to Smart Mapping’s ability to offer suggestions about which target elements should associated with a given source element based on certain user configurable factors.  Simply put, you select a source element and the Smart Mapper gives you the target elements that the source should map to.

It could suggest one or it could suggest a list of potential matches, it all depends on which Smart Mapping methods (Matching, Synonym, Property or History) you have active and how they are configured.  If the Smart Mapper offers a list of possible matches it will present them in a order of precedence based on how confident it believes the matches to be correct with the most confident match first down to its least confident match last.  Again, this is based on which methods are active and how those methods are configured.  You also have the ability to tell the Smart Mapper to use any suggestion from the list if the most confident suggestion is not to your liking.

So we’ve matched elements up, but that’s not enough.  Matching the source elements to the target elements is only half the battle.  It doesn’t actually get us anywhere unless we have rules representing these matches that actually tell EBI to do something with the data.  That’s where “Rule Generation” comes in.

Rule generation is the Smart Mapper’s ability to take the matches and turn them into actual rules in the EBI Ruleset Editor.  So when your dealing with a source data, not only will the Smart Mapper offer suggestions as to what target data the source should be paired with, but it will physically create the rules that represent these matches.

But wait, it gets better!  As most of you know, EBI rules are associated with things we like to call ‘actions’.  Rules represent the pairing of source and target data while actions describe what is to be done with the data.  Most often the action associated to a given rule is a ‘Move’ action.  Simply put, EBI takes the data in the source node and ‘moves’ it to the target node.  Although the ‘move’ action is most common, you are definitely not limited to it.  Other actions could include simple math functions, or string manipulations, or SQL queries, or complex Java programs.  So what do actions have to do with Smart Mapping?  Well I’ll tell you.  The Smart Mapper, using the something we call the ‘History Method’, can look into maps you’ve done in the past and not only make suggestions for matches based on those maps, but make suggestions for what actions to use with those matches.

For example, in the past I my have created a map that has A and B in the source, and 1 and 2 in the target.  A was mapped to 1 using a ‘move’ action and B was mapped to 2 using a custom formatting action.  I tell the Smart Mapper to use this map as history data while working in a new map that also contains B (or something very close to it ) in the Source and 2 (or something very close to it) in the target.  It naturally will the new B to the new 2 and will also suggest using the custom formatting action because that’s what I did in past.

The Smart Mapper’s rule generation capabilities aren’t just limited to creating rules from suggested matches and setting the action.  The Smart Mapper can also generate rules that you may not have explicitly asked it to.  Generally, the nodes you want to Smart Map have a one-to-one relationship with the number of rules being generated.  However, under certain circumstances, the Smart Mapper may generate additional ‘Composite Rules’ or ‘For Each Rules’ if it sees the need to create looping structures over nodes that can repeat in the source.

As you can see, the Smart Mappers ability to match and generate rules can be a useful tool in your mapping repertoire.  Allowing EBI to assist you during the mapping process can greatly reduce the time and effort it takes to produce a map, which in turn can greatly reduce the time it takes for you to set up an implementation.  Stay tuned to learn more about Smart Mapping and how it can aid your implementation efforts.

Leave a Reply

Your email address will not be published. Required fields are marked *


*