Hi Manoj,
By Schema:
- In the schema you can do quick promotion for a non repeating field, it creates a property schema with the field name.
- You can update / access the promoted field value in the orchestration as well.
- This promoted field you can use in sending port for subscriptions.
By Component:
- if you are trying to promote a field using component and you want to use this for subscription purpose means, then below are the steps you need to follow.
1) Create a property schema with one field that you are going to use in sending port, using property schema wizard in your BizTalk project, optionally you can update the proper target namespace and deploy to the admin console.
2) Create a pipeline component that reads your incoming data, access
or read the XML field value from the incoming message using
XPath, write that value to the property schema field that you created above, against property
field, Property namespace - from property schema.
3) Create receive pipeline and add your component in any of the stages except the disassemble stage, deploy the pipeline,
GAC the component.
4) Create, send and receive ports, configure receive location with your receive pipeline, having custom component, update send port with filter using your custom
property schema with value.
5) you will be able to access this in orchestration as well.
Test the flow with proper deployment steps, you should be able to subscribe the message based on your field values promoted to your send ports configured with same value that you promoted.
Code
pInMsg.Context.Promote("Field", "Namespace", Value);
let us know if you face any issues in doing the above steps.
Thanks, SMSVikasK