Data Mapping and Transformation

When performing data migrations, data must be mapped from the legacy system to Janrain schema attributes and transformed into the format the Janrain platform uses. These mappings and transformations can be defined using a mapping table similar to the one shown below.

 Legacy Name  Legacy Format  Janrain Attribute  Janrain Format
 first_name  alphanumeric  givenName  alphanumeric
 city  alphanumeric  primaryAddress.city  alphanumeric
 gender  "m", "f", "M", "F",
 "Male, "Female"
 gender  "male" or "female"
 DOB  "02/14/2010"  birthday  "2010-02-14"

For example, the legacy system has a field named first_name that maps directly to the Janrain user profile attribute givenName. Because both the legacy field and the user profile attribute employ the same data format (alphanumeric), data can simply be copied from the legacy system to Janrain. For example, if a user has the first_name Bob, that same name (Bob) will be copied to the givenName attribute in the user profile.

When it comes to the user's date of birth, however, there's more work involved than simply mapping the legacy field DOB to the user profile attribute birthday. That's because the DOB field uses a different datetime format (month/date/year) than the user profile (year-month-date). That means that a data transformation is needed to convert the value 02-14-2010 to the value 2010-02-14.

It's recommended that you complete a complete a similar mapping table for each legacy value you want to migrate to Janrain.

Note: The preceding are examples that illustrate the data mapping and transformation exercise. Actual mappings and transformations will be determined as part of an engagement with Janrain.

Related Articles