Content Conversion module in JMS Adapter - MessageTransformBean
Hi All,
We are using Content Conversion module using MessageTransformBean in JMS adapter to read a flat file from MQ Queue.It works fine and the file is getting picked and successfully converted into a xml structure in XI.
The flat file is multiple line file with each line as one xml record.But the xml structure after conversion has only one record in it.So we end up getting multiple messages each with one record instead of ONE xml structure with multiple records in it.
Could I know why I am not getting multiple records in one xml structure as expected.
Do I need to change xml.structureTitle as MyTitle,* or should I put something endSeparator like we do in File Content Conversion.
Any Help appreciated.
Thanks,
V
Edited by: CollinsV on Aug 9, 2010 6:28 AM
Edited by: CollinsV on Aug 9, 2010 6:36 AM
Edited by: CollinsV on Aug 9, 2010 6:38 AM
Edited by: CollinsV on Aug 9, 2010 6:39 AM
Edited by: CollinsV on Aug 9, 2010 6:56 AM
Thanks Shabarish .I did follow the same document , but the xml is not converted as multiple records in it .we are getting only one xml message for each record in the file .
The xml structure we are getting :
<ns:MyDocument xmlns:ns="http://xi.com/test">
<MyTitle>
<field-name1>111</field-name1>
<field-name2>222</field-name2>
<field-name3>333</field-name3>
</MyTitle>
</ns:MyDocument>
We need onle one xml message instead as below.
<ns:MyDocument xmlns:ns="http://xi.com/test">
<MyTitle>
<field-name1>AAA</field-name1>
<field-name2>BBB</field-name2>
<field-name3>CCC</field-name3>
</MyTitle>
<MyTitle>
<field-name1>111</field-name1>
<field-name2>222</field-name2>
<field-name3>333</field-name3>
</MyTitle>
</ns:MyDocument>
Any Help ...
Thanks
V
Similar Messages
-
I need this file "How to Use the Content Conversion Module in JMS Adapter"
Can someone send me this file:
"How to Use the Content Conversion Module in JMS Adapter"
I am not able to find it.
Thanks
Antonellopls refer guide
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/xi/xi-adapters/how%20to%20use%20the%20content%20conversion%20module%20with%20xi%203.0%20j2ee%20jms%20adapter.pdf
Regards,
Swetha. -
Content conversion in Sender JMS Adapter
Hi,
Scenario is file to IDoc
My source file is ' ; ' separated file coming from MQ via JMS adapter. now I need to convert this to XI.
Source DT looks like
Root
HEADER (Occurance 1)
Field 1
ISOCURCD
TRANKODE
IDENTIFIER
DATO
TIME
DETAIL(Occurance 1 to unbounded)
ISOCURCD
TRANKODE
EFFDATE
COMMDATE
DKKVAL1
USDVAL1
TRAILER(Occurance 1)
ISOCURCD
TRANKODE
TRANCOUNT
According to How to use content conversion in JMS guide from SDN i have configured the content conversion parameters in the module of JMS sender adapter.
In the processing sequence given the module name as localejbs/AF_Modules/MessageTransformBean and module Key as Plain2XML.
And in module configuration
Parameter Name Parameter Value
Transform.Class com.sap.aii.messaging.adapter.Conversion
Transform.ContentType text/xml;charset=utf-8
xml.keyFieldName TRANKODE
xml.keyFieldType CaseSensitiveString
xml.recordsetName Root
xml.documentName MT_ROOT
xml.documentNamespace http://XXX.XXX.XX/xi/XXXXX
xml.processFieldNames fromConfiguration
xml.conversionType StructPlain2XML
xml.recordsetStructure HEADER,1,DETAIL,*,TRAILER,1
xml.HEADER.fieldNames Field1,ISOCURCD,TRANKODE,IDENTIFIER,DATO,TIME
xml.HEADER.fieldSeparator ";"
xml.HEADER.keyFieldValue H
xml.fieldSeparator ";"(if i don't use this then the file is not being picked and getting an error in the CC monitoring of RWB saying xml.field separator missing.)
Similarily for Detail and Trailer records as well.
But when I run the scenario, the file is being picked up but I am not getting any payload into the inbound message.
Can you please help me where I have configured wrongly. And one more thing will this configuration help for ; separated file .
Thanks & Regards,
Kumar
Edited by: Kumar on Dec 19, 2007 11:11 AM
Edited by: Kumar on Dec 19, 2007 11:15 AMHI,
Have you gone through the below pdf i think it will help to find ur mistake.
How to use conversion modules in JMS - https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f02d12a7-0201-0010-5780-8bfc7d12f891
Thnx
Chiarg -
Content conversion question for JMS adapter
Hi,
I need to put this again here.
I have the scenario R/3 IDoc -> XI -> MQ (webshpere). MQ requires plain text.
I have the IDoc ORDERS05 in multi level (nested in layers). But using the how to guid to convert the content I could go up to on level.
Based on the thread
Process Integration (PI) & SOA Middleware
It is not possible to use the conversion modules with XML2Plain key with parameter xml.conversionType value StructXML2Plain.
Please confirm if this is possible to convert a structure like below,
<ZSYSEX01>
.<IDOC BEGIN="1">
....<EDI_DC40 SEGMENT="SEGMENT0">
........<FIELD1>HEADER</FIELD1>
....</EDI_DC40>
....<E1STATS SEGMENT="SEGMENT1">
........<FIELD2>100</MANDT>
........<Z1HDSTAT SEGMENT="SEGMENT2">
...........<FIELD3>0200000716</FIELD3>
...........<Z1ITSTAT SEGMENT="SEGMENT3">
...............<FIELD4>1000</FIELD4>
...........</Z1ITSTAT>
........</Z1HDSTAT>
........<Z1HDSTAT SEGMENT="SEGMENT2">
...........<FIELD3>0200000717</FIELD3>
...........<Z1ITSTAT SEGMENT="SEGMENT3">
...............<FIELD4>1000</FIELD4>
...........</Z1ITSTAT>
...........<Z1ITSTAT SEGMENT="SEGMENT3">
...............<FIELD4>1001</FIELD4>
...........</Z1ITSTAT>
...........<Z1ITSTAT SEGMENT="SEGMENT3">
...............<FIELD4>1002</FIELD4>
...........</Z1ITSTAT>
........</Z1HDSTAT>
....</E1STATS>
.</IDOC>
</ZSYSEX01>
to plain text in JMS adapter.
Thanks!
JasonHi,
You have to use Content Converiosn in JMS Adapter Receiver side,
Module Sequence in the Receiver Channel
No. Module Name Module Key
1 localejbs/AF_Modules/MessageTransformBean XML2Plain
2 localejbs/SAP XI JMS Adapter/ConvertMessageToBinary CallJMSService
3 localejbs/SAP XI JMS Adapter/SendBinarytoXIJMSService Exit
Bases on Structure you have to configure the processing parameters,
please see the below link, it will helps you more
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f02d12a7-0201-0010-5780-8bfc7d12f891
Regrads
Chilla.. -
Content conversion in Sender JMS adapter-document
Hi,
I am tring to read fixed length flat file from MQ-series Queue using JMS adapter.
I want to use content converstion to convert the flat file to XML.
I am not able to open the PDF link provided in SDN.
if anyone has a copy of the pdf document on JMS content conversion, could you please enmil it to me
at [email protected]
Edited by: ashok sri on May 27, 2008 5:25 PMplease go through the document
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/50061bd9-e56e-2910-3495-c5faa652b710 -
Content Conversion - JDBC and JMS
Can we use File Content Conversion with JDBC and JMS ?
Hi,
How To Use the Content Conversion Module in JMS Adapter - https://websmp106.sap-ag.de/~form/sapnet?_SHORTKEY=01100035870000582377&
check this for JMS content conversion:
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f02d12a7-0201-0010-5780-8bfc7d12f891
Check the how to guide provided by prabhu and also this link on the XMl To TeXtCoversion Module,
http://help.sap.com/saphelp_nw04/helpdata/en/44/748d595dab6fb5e10000000a155369/content.htm
Ref How To Use the Content Conversion Module in JMS Adapter -
https://websmp106.sap-ag.de/~form/sapnet?_SHORTKEY=01100035870000582377&
See this weblogs which was shown with examples:
How to use SAP's WebAS J2EE's JMS Queue in Exchange Infrastructure
Sync/Async communication in JMS adapter without BPM (SP19)
Async/Sync Communication using JMS adapter without BPM (SP 19)
Exploring JMS and SAP-XI JMS Adaper
Configuring the sender JMS adapter
http://help.sap.com/saphelp_nw2004s/helpdata/en/f4/2d6189f0e27a4894ad517961762db7/content.htm
Configuring the receiver JMS adapter
http://help.sap.com/saphelp_nw2004s/helpdata/en/10/b1b4c8575a6e47954ad63438d303e4/content.htm
Check JMS Adapter section of this blog by Sravya:
Aspirant to learn SAP XI...You won the Jackpot if you read this!-Part III
Also information related to Provider-specific settings are available
http://help.sap.com/saphelp_nw2004s/helpdata/en/cd/d85a9d6fab7d4dbb7ae421f710626c/frameset.htm
Plz do refer the following threads:
JMS Content Conversion - no CR/LF
Message (Data) getting lost after JMS Content Conversion(Sender)
Message (Data) getting lost after JMS Content Conversion(Sender)
Message (Data) getting lost after JMS Content Conversion(Sender)
Regards,
Vinod. -
Complex XML to Plain in JMS adapter "Content conversion module"
Hi!
I have read the document on "How To use the content conversion module with XI3.0 J2EE JMS Adapter", and it says only SimpleXML can be converted in the receiver channel.
I had hoped for a solution at least as good as in the File/ftp adapter, where complex XML can be transformed to files.
Are there plans to include complex XML conversion in the JMS adapter?
I can not use the file adapter as I need to change the file name and destination, and that can not be done by adding own module to its single module.
Any idea how I can achieve what I want?
To only way I can find, is to create a file using the file/ftp adapter, and then pick it up again and treat all the lines as the same structure (one row = one xml field). Then output this new xml message to file, using the JMS adapter and add any modules with name and destination determination.
Appreciate any help!
Regards,
Oeystein EmhjellenHello,
Have you tried to use an XSLT mapping within the IE?
I have, at one customer site, created a XSLT message mapping which converts the XML to a fixed length ASCII file format. I than added the XSLT message mapping as a second mapping step on the interface mapping.
In this case I was able to publish a fairly complex fixed length file format to MQ Series via the JMS adapter.
/Johan -
File Content Conversion in Sender File Adapter
Hi,
I am implementing a scenario, where I need to do Content conversion in My file Adapter.My input file is as follows
BGN00S-A200711281003ET4
REF38381012
DTP007D820071128
N1P5P5MicrosoftFI58-0612397
INSY18030XNAN
REFZZZZ666666666
DTP336D819970331
NM1ILIL1AdamsMarkE34666666666
PERIPIPHP770555-5555
N31470 Georgia Club Drive
N4StathamGA30666
DMGD819571022MM7
HD030HLTAE1D
My data type is as below.
<header>
<BGN>
<A></A>
<B></B>
<C></C>
<D></D>
</BGN>
<REF>
<A1></A1>
<B1></B1>
<C1></C1>
<D1></D1>
</REF>
<DTP>
<A2></A2>
<B2></B2>
<C2></C2>
<D2></D2>
</DTP>
</header>
<Content>
<N1>
<A></A>
<B></B>
<C></C>
<D></D>
</N1>
<REFAR>
<A1></A1>
<B1></B1>
<C1></C1>
<D1></D1>
</REFAR>
<DMP>
<A2></A2>
<B2></B2>
<C2></C2>
<D2></D2>
</DMP>
</Content>
My issue is, How do I set my parameter in Sender Comm channel for content conversion especially at record structure.
I have provided the value as Header,1,Content,*
But its not working.
If I do provide like
BGN_REC,,REF_REC,,DTP_REC,,N1_REC,,INS_REC,,NM1_REC,,PER_REC,,N3_REC,,N4_REC,,DMG_REC,,HD_REC,* then ,I am not getting above XML format. Please suggest or How can I modify my Data type which competes to configure in Channel
Thanks
ManmadhaHi All,
I am sorry for the Jumbled Content. I dont know what happened.
I should get the XML output as below.
header>
<BGN>
<A></A>
<B></B>
<C></C>
<D></D>
</BGN>
<REF>
<A1></A1>
<B1></B1>
<C1></C1>
<D1></D1>
</REF>
<DTP>
<A2></A2>
<B2></B2>
<C2></C2>
<D2></D2>
</DTP>
</header>
<Content>
<N1>
<A></A>
<B></B>
<C></C>
<D></D>
</N1>
<REFAR>
<A1></A1>
<B1></B1>
<C1></C1>
<D1></D1>
</REFAR>
<DMP>
<A2></A2>
<B2></B2>
<C2></C2>
<D2></D2>
</DMP>
</Content> -
Problem with file content conversion in receiver file adapter
Hi All
I have a problem with file content conversion in receiver file adapter.
This is my recordset structure: Header_Record,1,Claim_Record,*,Check_Rec,1
These are the content conversion parameters:
Header_Record.fieldSeparator = ,
Header_Record.endSeparator = 'nl'
Claim_Record.fieldSeparator = ,
Claim_Record.endSeparator = 'nl'
Check_Rec.fieldSeparator = ,
Check_Rec.endSeparator = 'nl'
In SXMB_MONI, i can see that the data is correctly extracted from proxy, and correctly mapped to receiver message, and i see a checkered flag (success).
But, Adapter status is RED with the following error message:
Conversion initialization failed: java.lang.Exception: java.lang.Exception: Error(s) in XML conversion parameters found: Parameter '1.fieldFixedLengths' or '1.fieldSeparator' is missing
In communication channel monitoring, i get the following error message:
Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Channel has not been correctly initialized and cannot process messages
What is going wrong here? Can anyone please tell me?
Thanks
ChandraPosted in Incorrect forum.
Posted again in Process Integration forum -
Content Conversion in File Receiver Adapter
Hi,
I am doing a Content Conversion in File Receiver Adapter.
Input to the Adapter is:
<ns1:FileResponse_MT xmlns:ns1="http://www.bpmtest.com/bpm">
<OrderID>123</OrderID>
<Quantity>98</Quantity>
<Price>76.23</Price>
</ns1:FileResponse_MT>
Desired output is: <b>OrderID# Quantity# Price (123#98#76.23)</b>
I tried to accomplish this with different settings in Recordset Structure and Conversion Parameters but could not achieve it, every time an empty file is produced.
Would appreciate any help on this.
Best Regards,Hi,
Enclose your structure with a parent element like this.
<ns1:FileResponse_MT xmlns:ns1="http://www.bpmtest.com/bpm">
<parent>
<OrderID>123</OrderID>
<Quantity>98</Quantity>
<Price>76.23</Price>
</parent>
</ns1:FileResponse_MT>
Then give the parameters, it will work.
parent.fieldSeparator = '#'
parent.endSeparator = 'nl'
Regards,
P.Venkat -
Content conversion in Sender JMS channel
Hello All,
My scenario is JMS to Proxy. SAP PI receives a flat file from JMS application.
Can any one please help us on converting flat file to XML conversion within sender JMS adapter
Thanks&Regards,
MoorthyHi
Check this
conversion type StructPlain2XML
conversion type SimplePlain2XML -
IMAP Sender channel, Content Conversion Module , target XSD structure issue
Hi,
I'm using the content conversion adapter module in my IMAP senderchannel , to transform a flat file into a IDOC ORDERS05 structure.
I have some difficulties generating the right structure... how can I make a more deep structure ?
My output is like this. All created segment is on the same level.
<ORDERS05>
<IDOC>
<E1EDK01>
<E1EDK03>
<E1EDKA1>
<E1EDK02>
<E1EDKT1>
<E1EDKT2>
<E1EDKT2>
<E1EDKT1>
<E1EDKT2>
<E1EDKT2>
<IDOC>
</ORDERS05>
Here the E1EDKT2 should be a "level under" or "sub structure" to E1EDKT1, and not on the same level !
The wanted result:
<ORDERS05>
<IDOC>
<E1EDK01>
<E1EDK03>
<E1EDKA1>
<E1EDK02>
<E1EDKT1>
<E1EDKT2>
<E1EDKT2>
<E1EDKT1>
<E1EDKT2>
<E1EDKT2>
<IDOC>
</ORDERS05>
How can I solve this ????Hi,
you can do it on adapter level too:
but you cannot do it in standard content conversion I guess
(if it has more then 2 levels)
check this how you can do it:
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/482aae19-0301-0010-3485-8efd618818d0
Regards,
michal
<a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a> -
Problems with content conversion in File Receiver Adapter
Hello, everybody.
I have a RFC-to-File scenario with file content conversion. Everything is working well except that my file is generated with 2 blank lines at the top of it.
The function module has 3 importing parameters (1 optional) and the file content comes from an internal table.
Is it caused by the function module parameters? If yes, how can I avoid this, once I really need them? If not, does anyone have any idea?
Thanks a lot,
Marcos.Hi, Raj.
Here they are the function module parameters:
Importing parameters:
ICARRIER TYPE CHAR1
FPATH TYPE IPATH
IFILE LIKE VBAK-BNAME
Tables
IYLASDS_RECPT LIKE YLASDS_RECPT
The structure YLASDS_RECPT has only one field with a single line of the file. I am using this field as the <i>Recordset Name</i> inside file adpater parameters.
There is no mapping between RFC and FTP messages.
Thanks a lot,
Marcos. -
File Content Conversion Parameters in FIle Adapter
Hi
I am doing a scenario - XML file to Text file using File content conversion parameters in Receiver File Adapter Channel.
I given FCC Parameters like:
DATA.addHeaderLine - '0'
DATA.fieldSeparator - ,
DATA.endSeparator - 'nl'
But im getting error in Receiver File Adapter as - fieldSeparator not specified.
i would be greatful if any one help me.
Regards
RajeshHi Rajesh,
There are lot of blogs which explain File Content Conversion in different scenarios:-
/people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1
/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2
/people/venkat.donela/blog/2005/06/08/how-to-send-a-flat-file-with-various-field-lengths-and-variable-substructures-to-xi-30
/people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file
/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion
/people/shabarish.vijayakumar/blog/2005/08/17/nab-the-tab-file-adapter
/people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns
/people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem
/people/sap.user72/blog/2005/01/06/how-to-process-csv-data-with-xi-file-adapter
/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter
I hope this helps.
Regards.
Praveen -
REG: File content conversion in Receiver file adapter
HI Gurus,
I have the scenario like proxy to file with content conversion
my message type for the source like this
MT_SOURCE
-----||
|---ROW
------------||
|---LINE
target strucuture also same
MT_TARGET
-----||
|---ROW
------------||
|---LINE
i am using the following FCC parameters in receiver file adapter
LINE.fieldSeparator = ' '
LINE.fixedLineWidth = 90
LINE.lineSeparator = 'nl'
LINE.fieldFixedLengths = 200
LINE.endSeparator = 'nl'
the output file show the data differently in note pad when compare to word
word output
dgepvs 023456987
kgdd0016155710 SS Smw Ne 01
kgdd0016155710 SS Smw Ne 01
kgdd0016155710 SS Smw Ne 01
kgdd0016155710 SS Smw Ne 01
kgdd0016155710 SS Smw Ne 01
kgdd0016155710 SS Smw Ne 01
kgdd0016155710 SS Smw Ne 01
notepad out put
dgepvs 023456987 kgdd0016155710 SS Smw Ne 01 kgdd0016155710 SS Smw Ne 01 kgdd0016155710 SS Smw Ne 01 kgdd0016155710 SS Smw Ne 01 kgdd0016155710 SS Smw Ne 01
word output is the correct output wat i am expect but same out put i want in note pad can any help me out for this how can i resolve this
Thanks in advanceThere is nothing wrong in your content conversion parameters. This is pure editors interpretation for the next line character.
I would do in java program to fix this issue using '\r\n' You might want to try and see how that helps for notepad editor.
Maybe you are looking for
-
My MacBook Pro is acting really strange and unusual
Please read my 3 part chronicle named 'The Tribulations of M. B. Pro' Pictures featured at end. I recently showed an apple techy (in-store) a picture of what my laptop displayed the other day and he said he didn't know but I should bring it in asap
-
How do I get my iPod out of the recovery mode loop?
While I was updating my iPod Touch 5g (32GB) to the latest iOS 6.1, the USB by mistake got ditached from my mac and the iPod's screen turned to a USB pointing towards the iTunes logo(Recovery Mode). It showed the same thing when I restarted it around
-
How to use a custom KeyManager in nonblocking SSLSocketChannel
In our existing project I had to replace the nonblocking SocketChannel by nonblocking SSLSocketChannel. My implementation of the nonblocking SSLSocketChannel hides all the SSL stuff and can be used like a SocketChannel in the whole project you just h
-
PPOME - Adding a new 1001 relationship
All, We have created a new relationship in OM infotype 1001. The business would like to maintain this relationship in PPOME. Anyone know how to add this new relationship into PPOME. I take it code is involved somehow to get the fields there? Any h
-
Help! iPod won't connect to computer
So, I got a new iPod Touch 5g about a month and a half ago and it was connecting to my computer just fine up until about 2 weeks ago when I updated my iTunes. I have an HP laptop that runs on Windows 8.1. I have gone through all of the steps that eve