on 02-16-2011 9:03 AM
i have a problem and i d'ont konw how to solve.
In message mapping, I have :
1. A message type origin with next structure:
<?xml version="1.0" encoding="UTF-8"?>
<ns0:CRSC_MT_Fichero xmlns:ns0="http://cccc/wwww">
<Record>
<Row>row1</Row>
</Record>
<Record>
<Row>row2</Row>
</Record>
</ns0:CRSC_MT_Fichero>
2. A message type target with next structure:
<?xml version="1.0" encoding="UTF-8"?>
<ns1:EnviarFicheroBandeja xmlns:ns1="http:/xxxxx/">
<ns1:cifOrigen>Origen</ns1:cifOrigen>
<ns1:fichero>row1</ns1:fichero>
</ns1:EnviarFicheroBandeja>
we want it is that in field fichero ( xsd:base64Binary) has the content of every Rows together.
So in the below example we would like as result:
<?xml version="1.0" encoding="UTF-8"?>
<ns1:EnviarFicheroBandeja xmlns:ns1="http:/xxxxx/">
<ns1:cifOrigen>Origen</ns1:cifOrigen>
<ns1:fichero>row1
row2
</ns1:fichero>
</ns1:EnviarFicheroBandeja>
thanks
Use concat Standard function in message mapping graphical editor. You can find it under Text.
use like this
Row 1
concat -
Row1Row2.
Row 2
use concat !!
Thanks
Aashish Sinha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
above reply got weired.. Sorry for that..
Just use concat function and provide source and target.
do it like this
Source1 Source2
|----
Concat -
>Outputtag
Concat tag contains 2 input and 1 output.
so give both tag as input to concat and 1 output to your desired field.
Regards
Aashish Sinha
Edited by: Aashish Sinha on Feb 16, 2011 11:28 AM
something weired is happening..
Look this out
concat
R = linking of strings X and Y (without blanks).
Example: X = u201CMrs.u201D; Y = u201CMilleru201D; R = u201CMrs.Milleru201D. Use the dialog for the function properties to insert a separator in the string
link :http://help.sap.com/saphelp_erp2004/helpdata/en/43/c4cdfc334824478090739c04c4a249/content.htm
Use n concat function as
Name & name ->concat -> output to some constant and the constant as 1 input to concat function and other name is another input to concat function and repeate first step until you get what you want.
it will be like :
name1 & name2 -> concat func -> Output & name3 -> concat -> output & name 4 and so on..
regards
Aashish
Hello,
This is not possible without the use of UDF. You can use this mapping:
Row --> removeContext --> UDF --> fichero
UDF is of queue type
Argument: input
StringBuffer sb = new StringBuffer("");
for(int a=0;a<input.length;a++){
sb = sb.append(input[a]+" ");
}
result.addValue(sb.toString());
Hope this helps,
Mark
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
9 | |
9 | |
9 | |
6 | |
6 | |
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.