on 05-31-2013 1:34 PM
Hey,
I have a problem in a graphical mapping and need to remove a "SUPPRESS" entry in the queue. There are several entries in the queue and one of them is "SUPPRESS", and this entry causes a wrong result of the mapping. I have tried several possibilities, but I haven't found a fitting solution yet.
Does anyone know how to handle this issue?
Thanks a lot!!
Sebastian
Hi Sebastin,
Try this UDF
public void removeSUPPRESS(String []Input,ResultList result,Container container) throws StreamTransformationException
{
for(int i=0;i<Input.length;i++)
{
if(!(Input<i>.equals(ResultList.SUPPRESS)))
{
result.addValue(Input<i>);
}
}
}
It simply removes all the SUPPRESS entries that you have in your display queue and will pass only the non SUPPRESS values to the output.
modify the code according to your requirement.
Or
You can use remove context, followed by the Split by value.
Hope it will helpful..
Regards
Bhargava krishna
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sebastian,
You can try removeContext/split by Value but if the source queue has variable values in the contexts, it won't work else try with the UDF suggested in other posts to check ResultList.SUPPRESS and that should work.
Ambrish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sebastian,
You can use below UDF to achieve your requirement:
public void removeSuppress(String[] contextValues, ResultList result, Container container)
{
if (contextValues != null && contextValues.length > 0)
{
for (int i = 0; i < contextValues.length; i++)
{
if (contextValues[i] != null && !ResultList.SUPPRESS.equalsIgnoreCase(contextValues[i]))
{
result.addValue(contextValues[i]);
}
}
}
}
Thanks
Rakesh Sharma
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sabastian,
Using the following UDF should clear your issue...
public void RemoveSuppress(String[] a,ResultList result,Container container){
for (int i=0; i<a.length;i++)
{
if (!a<i>.equalsIgnoreCase(ResultList.SUPPRESS))
{
result.addValue(a<i>);
}
}
Regards,
DNK Siddhardha.
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 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.