Friday, 6 December 2013

BizTalk Value Cross Reference

If you dont have idea on Biztalk Cross Reference data. Please go through my previous blog on Biztalk Cross Reference

Value CROSS REFERENCE:

Scenario:

Field Common Value Application1 ID Application 2 ID Application 3 ID
Type tax TA Bounded ST

Solution:

  1. Create XML files that represent cross reference data.

    listOfAppType.xml

    listOfAppInstance.xml

    listOfValueXRef.xml

    listOfValueXRefData.xml

    SetupFile.xml

  2. Now you have all the data that you need for your Value cross Reference. Now deploy these data to the BizTalk Management Database.

    Give the following Command in your command prompt.

    btsxrefimport –file=SetupFile.xml

  3. Using the cross reference in your map.

    From the Tool box drop the Get Common Value Functoid and connect the type field from your source schema to it.

    Double Click the Get Common ID Functoid and add 2 more inputs as shown below

    Re arrange the input parameters order as follows. Otherwise you will get GetCommonValue() functiod failed as the method takes the parameters as follows:

    GetCommonValue(string valueXRef, string appType, string appValue);Ex:

    Ex:

    CrossReferencing.GetCommonValue("Type", "Application1", "TA")

    Now drop the Get Application Value Functoid and connect the output of Get Common Value Functoid to this one.

    Configure the Get Application Value Functoid Inputs as shown below.

    Re arrange the input parameters order as follows. Otherwise you will get GetAppValue() functiod failed as the method takes the parameters as follows:

    GetAppValue(string valueXRef, string appType, string commonValue)

    Ex:

    strCommonValue = CrossReferencing.GetCommonValue("Type", "Application1", "TA");

    strCompany2AppValue = CrossReferencing.GetAppValue("Type", "Application2", strCommonValue);

    The Output of this Functoid will be the equivalent Application2 value for the Application1 Input.

    Similarly Map for the Application1 and Application3.

Output:

Input message:

Output message:

No comments:

Post a Comment