If you dont have idea on Biztalk Cross Reference data. Please go through my previous blog on Biztalk Cross Reference
ID Cross Reference:
Scenario:
Field | Common ID | Application1 Value | Application2 Value | Application03 Value |
Status | 1 | Open | Entered | Started |
Status | 2 | Closed | Done | Finished |
Solution:
-
Create XML files that represent cross reference data.
listOfAppType.xml
listOfAppInstance.xml
listOfIDXRef.xml
listOfIDXRefData.xml
SetupFile.xml
-
Now you have all the data that you need for your ID cross Reference. Now deploy these data to the BizTalk Management Database.
Give the following Command in your command prompt.
btsxrefimport –file=SetupFile.xml -
Using the cross reference in your map.
From the Tool box drop the Get Common ID Functoid and connect the Status 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 as follows otherwise GetCommonID() functiod failed as the method takes the parameters as follows:
GetCommonID(string idXRef, string appInstance, string appId);
Ex: CrossReferencing.GetCommonID("Status", "Application1Instance", "Open");
Now drop the Get Application ID Functoid and connect the output of Get Common ID Functoid to this one.
Configure the Get Application ID Functoid Inputs as shown below.
Re arrange the input parameters order as follows. Otherwise you will get GetAppID() functiod failed as the method takes the parameters as follows:
GetAppID(string idXRef, string appInstance, string commonId)
Ex:
strCommonID = CrossReferencing.GetCommonID("Status", "Application1Instance", "Open");
strApp22AppID = CrossReferencing.GetAppID("status", "Application2Instance", strCommonID);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