Oracle Central Coding mapping

Perform mapping on for Central Coding questions.

Rule description: When a codelist value is mapped to Oracle Central Coding and includes 'Other' as an option for a field (ROUTE), user will be requested to specify in another text field (ROUTEOTHR), then we will map the specified text to the codelist value in the following format: "Other: {ROUTEOTHR}".

Rule expression

if (ROUTE !== null)
 {
    return (ROUTEOTHR === null ? getStringFromChoice(ROUTE) : (getStringFromChoice(ROUTE) + ': ' + ROUTEOTHR));
 }
else
 {
    return '';
 }

Definitions

ROUTE

Corresponds to the mapped codelist value item (ROUTE) from the rule description.

ROUTEOTHR

Corresponds to the specified text item (ROUTEOTHR) that needs to be mapped along the 'Other' codelist value from the rule description.

Return value

String

The route item is a choice control and the rule is mapping data entered in choice control to a text item.

Verification steps

  1. Using a subject for testing, go to the given visit and form containing the items to map, in this example the dropdown question administration route <ROUTE>, and specify <ROUTEOTHR> displayed when selecting "Other" as an answer.
  2. Update the form items ROUTE, and ROUTEOTHR when prompted, as in the following table and verify the result is as listed:
    ROUTE ROUTEOTHR Result
    'Oral' NA. Target item is populated as 'Oral'.
    'Topical' NA. Target item is populated as 'Topical'.
    'IM' NA. Target item is populated as 'IM'.
    'Other' Null Target item is populated as 'Other'.
    'Other' 'Unknown' Target item is populated as 'Other: Unknown'.
    Null Null Target item is cleared.

Note:

Repeat the above steps if the form is present in multiple visits.

Other examples

Example 4-3 Details from Route and Route Other specify should be mapped to Route of Administration

Note:

If CMROUTE = Other and CMROUTEOTH = null then NO VALUE will be populated in Route of Administration

if(CMROUTE===null || cmrouteoth===null){}
var txt=getStringFromChoice(CMROUTE);
if(txt==='Other')
{
   return cmrouteoth!==null? cmrouteoth : "NO VALUE";
}
else if(txt!==''){
    return txt;
}else
{
    return '';
}