on 04-08-2016 10:36 AM
HI All.
I want to remove the Suppress which is coming result of CreateIf.
even i tried UDFs which is available in other threads.
first i tried to remove the SUPPRESS using blow code
and the result is, it not removing the SUPPRESS, and in place of suppress i'm getting null.
and aging i tried one more UDF to remove the null which is available in other thread as mentioned below.
and now i can able to remove the SUPPRESS but it's not giving the proper count of values, it's giving only one output for every context change.
based on this example expected result is
[]
[]
context change
[]
[]
context change
[]
[]
context change
please do needful.
Thanks and regards.
Hi Ramesh,
Use below mapping after remove contexts in your mapping logic.
REC_TYPE equals to EMPLOYEE --->removeContexts--->UDF--->employees(Node)
UDF:
Execution Type: All Values Of Context.
public void mapEmployeeNode(String[] input, ResultList result, Container container) throws StreamTransformationException {
for (int i = 0; i < input.length; i++) {
if (input[i].equals("false")) {
if (i != 0)
result.addContextChange();
} else
result.addValue("");
}
}
Regards,
Praveen.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.