on 10-05-2007 10:23 AM
Hi,
I want to put one condition in my mapping.. that is.. if the input field is particular value( for example input field value is <b>*</b> ).. then i want to skip the mapping... otherwise mapping will be need to execute normally..
based on this condition.. what are the nodes and what are the functions we need to take..
Thanks
Babu
>>>if the input field is particular value( for example input field value is * ).. then i want to skip the mapping... otherwise mapping will be need to execute normally..
You can use XPath expression/context objects to achieve this @ interface determination or Receiver Determination.
Regards,
Jai Shankar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Havent tried but: In Interface Determincation step -> standard -> try using more than one interfaces and interface mapping.
Regards,
Prateek
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
What do you mean by skip mapping....do you want to break mapping?
If structures would be...
source
-val1
-val2
target
-trgt1
-trgt2
one solution is check source field->equalsS->(constant).....(creatif) then generate 'target' node.This will help you out.
Regards,
Akshay.
reward points if find useful.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
can you please clarify on the line skip the mapping:
and according to your question you can use the following functions in mapping
you can use the following udf
for(int i=0;i<a.length;i++)
{
if(a<i>.equals("*"))
{
result.addValue(ResultList.SUPPRESS);
}
else
{
result.addValue(b);
}
}
in udf a in the field on which you are checkingg the condition
and b is the output that you want to pass on the true condition
if you still have doubt please reply back
Thanks
Rinku
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi BABU,
Use <b>IF, EQUALS, NOT</b> & <b>CONSTANT</b> functions to map your target field as shown below.
<b>IF</b> <b>NOT</b> InputFiels <b>EQUALS</b> constant value<b>"*"</b> THEN -
> TargetField.
By mapping this way it will check all <b>""</b> values coming from your input fields, and will only pass those values which don't have <b>""</b> value.
Regard,
Sarvesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Babu,
Use the XPath expression in the receiver determination.
XPATH:
XPath is an expression language that allows the processing of values conforming to the data model which provides a tree representation of XML documents as well as atomic values such as integers, strings, and booleans. The result of an XPath expression may be a selection of nodes from the input documents, or an atomic value, or more generally, any sequence allowed by the data model. It is an hierarchic addressing of the nodes in an XML tree.The primary purpose of XPath is to address the nodes of XML trees. XPath is designed to be embedded in a host language such as XSLT and XML.
<a href="http://www.w3.org/TR/xpath20/">XPATH</a>
Also have a looka th this blogs
<a href="/people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination your 'XPATH' Expressions in Receiver Determination</a> By Shabarish Vijayakumar
<a href="/people/shabarish.vijayakumar/blog/2005/08/03/xpath-to-show-the-path-multiple-receivers to show the path (Multiple Receivers)</a> By Shabarish Vijayakumar
Regards
San
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi
In graphical mapping u have function mapWithDefault.
This will solve your problem. Go through this blog as an example
<a href="/people/stefan.grube/blog/2005/12/29/new-functions-in-the-graphical-mapping-tool-xi-30-sp13:///people/stefan.grube/blog/2005/12/29/new-functions-in-the-graphical-mapping-tool-xi-30-sp13
Please reward points if u find it useful
Anu Singhal
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.