Transformation program (Conversion)
Hi Friends,
Could you suggest me how to develop a program to transform the data from Mainsaver(old system) to ECC6.0 and finally it will uploaded to ECC6.0 using LSMW .
Example: Mapping of data for Material group for service item
Mainsaver ECC6.0
VECHCL 12345678
Please revert me with some solution.
Thanks in advance,
BABA
Hello Ravinder,
Can you please post the complete stack trace, it seems to be some fields are getting truncated i,e data sent from the program to the proxy object might be violating some length restrictions.
Please check your message interface field lengths and what is being passed to the proxy.
Regards,
Ravi.
Similar Messages
-
Hi Experts ,
i have a scenario proxy to soap where i am getting error while getting the response .
we are sending the request successfully and getting response .some times we are getting in proxy level error below
PARSE_APPLICATION_DATA Error during XML => ABAP conversion: Response Message; CX_ST_DESERIALIZATION_ERROR in /1SAI/SAS0446CC11CC6EC1AD4789 Line 24 An error occurred when deserializing in the simple transformation program /1SAI/SAS0446CC11CC6EC1AD4789 (Cha
Please help us to fix this bug in proxy response.
Regards
RaviHello Ravinder,
Can you please post the complete stack trace, it seems to be some fields are getting truncated i,e data sent from the program to the proxy object might be violating some length restrictions.
Please check your message interface field lengths and what is being passed to the proxy.
Regards,
Ravi. -
Debugging a XML Transformation Program
Hi,
We are converting incoming XML into ABAP structure and checking if the data has any future effective changes. If there is a future effective update, then it is converted back to XML string and stored in a custom table as a XML string. A job which runs picks up the record on the given date and process the changes that are to be applied. We are facing issues during the transformation which happens on this day(effective date. Though the XML string has data when the transformation is called, there is no ABAP output after transformation. Interesting things to note are:
. No Transformation error is thrown
When the same scenario with same XMLs is repeated in other regions(Dev & Quality), there are no issues at all
What I would like to know is
>> Is there any file encoding & xml string conversions issues?
>> is it possible to debug within the transfomation(ie transformation program) We tried STRANS, but were not able?
Any help is this regard is appreciated.
Thanks
GaneshRich,
I tried to do what you suggested but it didn't allow me to stop at the break-point.
Here is why I need to debug the program. Our sales orders just crossed over the number range for ITOs (inter company transfer orders). Where we are including the header text of the sales order it is pulling the header info of the ITO that has the same order number (from the numbers crossing). I need to figure out where/how to pull the header information based on the order type. The Order Confirmation is pulling the correct header text but I am unsure how it is doing that. I need to determine what the text name is from the Order Confirmation. On the Picklist the text name is the sales order number.
I hope that made sense.
Davis -
Simple transformation program debugging
hi ,
can any boby guide me how can we debug a simple transformation program which is used for xml to abap conversion .Hi,
have a look on this.
REPORT YMS_XMLTOSAP.
TYPE-POOLS: IXML.
TYPES: BEGIN OF T_XML_LINE,
DATA(256) TYPE X,
END OF T_XML_LINE.
DATA: L_IXML TYPE REF TO IF_IXML,
L_STREAMFACTORY TYPE REF TO IF_IXML_STREAM_FACTORY,
L_PARSER TYPE REF TO IF_IXML_PARSER,
L_ISTREAM TYPE REF TO IF_IXML_ISTREAM,
L_DOCUMENT TYPE REF TO IF_IXML_DOCUMENT,
L_NODE TYPE REF TO IF_IXML_NODE,
L_XMLDATA TYPE STRING.
DATA: L_ELEM TYPE REF TO IF_IXML_ELEMENT,
L_ROOT_NODE TYPE REF TO IF_IXML_NODE,
L_NEXT_NODE TYPE REF TO IF_IXML_NODE,
L_NAME TYPE STRING,
L_ITERATOR TYPE REF TO IF_IXML_NODE_ITERATOR.
DATA: L_XML_TABLE TYPE TABLE OF T_XML_LINE,
L_XML_LINE TYPE T_XML_LINE,
L_XML_TABLE_SIZE TYPE I.
DATA: L_FILENAME TYPE STRING.
PARAMETERS: PA_FILE TYPE CHAR1024 DEFAULT 'c:\temp\orders_dtd.xml'.
* Validation of XML file: Only DTD included in xml document is supported
PARAMETERS: PA_VAL TYPE CHAR1 AS CHECKBOX.
START-OF-SELECTION.
* Creating the main iXML factory
L_IXML = CL_IXML=>CREATE( ).
* Creating a stream factory
L_STREAMFACTORY = L_IXML->CREATE_STREAM_FACTORY( ).
PERFORM GET_XML_TABLE CHANGING L_XML_TABLE_SIZE L_XML_TABLE.
* wrap the table containing the file into a stream
L_ISTREAM = L_STREAMFACTORY->CREATE_ISTREAM_ITABLE( TABLE = L_XML_TABLE
SIZE = L_XML_TABLE_SIZE ).
* Creating a document
L_DOCUMENT = L_IXML->CREATE_DOCUMENT( ).
* Create a Parser
L_PARSER = L_IXML->CREATE_PARSER( STREAM_FACTORY = L_STREAMFACTORY
ISTREAM = L_ISTREAM
DOCUMENT = L_DOCUMENT ).
* Validate a document
IF PA_VAL EQ 'X'.
L_PARSER->SET_VALIDATING( MODE = IF_IXML_PARSER=>CO_VALIDATE ).
ENDIF.
* Parse the stream
IF L_PARSER->PARSE( ) NE 0.
IF L_PARSER->NUM_ERRORS( ) NE 0.
DATA: PARSEERROR TYPE REF TO IF_IXML_PARSE_ERROR,
STR TYPE STRING,
I TYPE I,
COUNT TYPE I,
INDEX TYPE I.
COUNT = L_PARSER->NUM_ERRORS( ).
WRITE: COUNT, ' parse errors have occured:'.
INDEX = 0.
WHILE INDEX < COUNT.
PARSEERROR = L_PARSER->GET_ERROR( INDEX = INDEX ).
I = PARSEERROR->GET_LINE( ).
WRITE: 'line: ', I.
I = PARSEERROR->GET_COLUMN( ).
WRITE: 'column: ', I.
STR = PARSEERROR->GET_REASON( ).
WRITE: STR.
INDEX = INDEX + 1.
ENDWHILE.
ENDIF.
ENDIF.
* Process the document
IF L_PARSER->IS_DOM_GENERATING( ) EQ 'X'.
PERFORM PROCESS_DOM USING L_DOCUMENT.
ENDIF.
*& Form get_xml_table
FORM GET_XML_TABLE CHANGING L_XML_TABLE_SIZE TYPE I
L_XML_TABLE TYPE STANDARD TABLE.
* Local variable declaration
DATA: L_LEN TYPE I,
L_LEN2 TYPE I,
L_TAB TYPE TSFIXML,
L_CONTENT TYPE STRING,
L_STR1 TYPE STRING,
C_CONV TYPE REF TO CL_ABAP_CONV_IN_CE,
L_ITAB TYPE TABLE OF STRING.
L_FILENAME = PA_FILE.
* upload a file from the client's workstation
CALL METHOD CL_GUI_FRONTEND_SERVICES=>GUI_UPLOAD
EXPORTING
FILENAME = L_FILENAME
FILETYPE = 'BIN'
IMPORTING
FILELENGTH = L_XML_TABLE_SIZE
CHANGING
DATA_TAB = L_XML_TABLE
EXCEPTIONS
OTHERS = 19.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Writing the XML document to the screen
CLEAR L_STR1.
LOOP AT L_XML_TABLE INTO L_XML_LINE.
C_CONV = CL_ABAP_CONV_IN_CE=>CREATE( INPUT = L_XML_LINE-DATA REPLACEMENT = SPACE ).
C_CONV->READ( IMPORTING DATA = L_CONTENT LEN = L_LEN ).
CONCATENATE L_STR1 L_CONTENT INTO L_STR1.
ENDLOOP.
L_STR1 = L_STR1+0(L_XML_TABLE_SIZE).
SPLIT L_STR1 AT CL_ABAP_CHAR_UTILITIES=>CR_LF INTO TABLE L_ITAB.
WRITE: /.
WRITE: /' XML File'.
WRITE: /.
LOOP AT L_ITAB INTO L_STR1.
REPLACE ALL OCCURRENCES OF CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB IN
L_STR1 WITH SPACE.
WRITE: / L_STR1.
ENDLOOP.
WRITE: /.
ENDFORM. "get_xml_table
*& Form process_dom
FORM PROCESS_DOM USING DOCUMENT TYPE REF TO IF_IXML_DOCUMENT.
DATA: NODE TYPE REF TO IF_IXML_NODE,
ITERATOR TYPE REF TO IF_IXML_NODE_ITERATOR,
NODEMAP TYPE REF TO IF_IXML_NAMED_NODE_MAP,
ATTR TYPE REF TO IF_IXML_NODE,
NAME TYPE STRING,
PREFIX TYPE STRING,
VALUE TYPE STRING,
INDENT TYPE I,
COUNT TYPE I,
INDEX TYPE I.
NODE ?= DOCUMENT.
CHECK NOT NODE IS INITIAL.
ULINE.
WRITE: /.
WRITE: /' DOM-TREE'.
WRITE: /.
IF NODE IS INITIAL. EXIT. ENDIF.
* create a node iterator
ITERATOR = NODE->CREATE_ITERATOR( ).
* get current node
NODE = ITERATOR->GET_NEXT( ).
* loop over all nodes
WHILE NOT NODE IS INITIAL.
INDENT = NODE->GET_HEIGHT( ) * 2.
INDENT = INDENT + 20.
CASE NODE->GET_TYPE( ).
WHEN IF_IXML_NODE=>CO_NODE_ELEMENT.
* element node
NAME = NODE->GET_NAME( ).
NODEMAP = NODE->GET_ATTRIBUTES( ).
WRITE: / 'ELEMENT :'.
WRITE: AT INDENT NAME COLOR COL_POSITIVE INVERSE.
IF NOT NODEMAP IS INITIAL.
* attributes
COUNT = NODEMAP->GET_LENGTH( ).
DO COUNT TIMES.
INDEX = SY-INDEX - 1.
ATTR = NODEMAP->GET_ITEM( INDEX ).
NAME = ATTR->GET_NAME( ).
PREFIX = ATTR->GET_NAMESPACE_PREFIX( ).
VALUE = ATTR->GET_VALUE( ).
WRITE: / 'ATTRIBUTE:'.
WRITE: AT INDENT NAME COLOR COL_HEADING INVERSE, '=',
VALUE COLOR COL_TOTAL INVERSE.
ENDDO.
ENDIF.
WHEN IF_IXML_NODE=>CO_NODE_TEXT OR
IF_IXML_NODE=>CO_NODE_CDATA_SECTION.
* text node
VALUE = NODE->GET_VALUE( ).
WRITE: / 'VALUE :'.
WRITE: AT INDENT VALUE COLOR COL_GROUP INVERSE.
ENDCASE.
* advance to next node
NODE = ITERATOR->GET_NEXT( ).
ENDWHILE.
ENDFORM. "process_dom
Thanks,
Sankar M -
The transformation program that is getting generated ( as $tmp ) from my web service has another transformation inside it, which doesn't get created properly. I have this issue with web services that are transported. The services that I create in that system is getting all the required transformations. Any idea why this is happening.
I cannot even transport a STRANS transformation?The problem is resolved with SAP note 1133941.
-
Help required in Transformations (XML Conversion)
Hi All,
Iam using transformations for reading the data from XML to Internal tables. Everything is working fine.
Here my question is, If some tags are missing in the XML file, program is giving error 'TAG XXX is missing'.
I dont want to get this error, if any tag is missing program should take the blank value instead of raising the error.
Please help. thanks.
Regards,
SreedharHi,
My transformation is as below... Please let me know you mail ID so that i will send XML format
<?sap.transform simple?>
<tt:transform xmlns:tt="http://www.sap.com/transformation-templates" template="temp">
<tt:root name="ROOT"/>
<tt:template name="temp">
<tt:loop ref="ROOT">
<!-- Read Header Details -->
<DESPATCHADVICE>
<!-- Profile ID -->
<PROFILEID>
<tt:value ref="$ref.profile"/>
</PROFILEID>
<!-- BOL Number -->
<tt:s-cond check="not-initial($ref.bol)">
<BOLID>
<tt:value ref="$ref.bol"/>
</BOLID>
</tt:s-cond>
<!-- CopyIndicator -->
<tt:s-cond check="not-initial($ref.copy)">
<COPYINDICATOR>
<tt:value ref="$ref.copy"/>
</COPYINDICATOR>
</tt:s-cond>
<!-- LineCountNumeric -->
<tt:s-cond check="not-initial($ref.lcn)">
<LCN>
<tt:value ref="$ref.lcn"/>
</LCN>
</tt:s-cond>
<!-- GrossWeightMeasure -->
<tt:s-cond check="not-initial($ref.gwm)">
<GWM>
<tt:value ref="$ref.gwm"/>
</GWM>
</tt:s-cond>
<!-- Pro Number -->
<tt:s-cond check="not-initial($ref.pro)">
<PROID>
<tt:value ref="$ref.pro"/>
</PROID>
</tt:s-cond>
<!-- DespatchAdviceTypeCode -->
<tt:s-cond check="not-initial($ref.dac)">
<DAC>
<tt:value ref="$ref.dac"/>
</DAC>
</tt:s-cond>
<!-- Reading Trailer Number and Scac code -->
<DOCUMENT_CONF>
<!-- Trailer Number -->
<tt:s-cond check="not-initial($ref.trailer)">
<TRAILERID>
<tt:value ref="$ref.trailer"/>
</TRAILERID>
</tt:s-cond>
<!-- SCAC Code -->
<tt:s-cond check="not-initial($ref.scac)">
<SCACCODE>
<tt:value ref="$ref.scac"/>
</SCACCODE>
</tt:s-cond>
</DOCUMENT_CONF>
<!-- Reading PO Details -->
<tt:loop name="details" ref="$ref.details">
<DESPATCH_CONF>
<!-- PO Number -->
<tt:s-cond check="not-initial($details.po)">
<PO_CONF>
<tt:value ref="$details.po"/>
</PO_CONF>
</tt:s-cond>
<!-- Item Number -->
<tt:s-cond check="not-initial($details.item)">
<ITEMID_CONF>
<tt:value ref="$details.item"/>
</ITEMID_CONF>
</tt:s-cond>
<!--Reading Material Details -->
<SHIPMENT_CONF>
<!--Material Details -->
<tt:s-cond check="not-initial($details.matnr)">
<MATERAIL>
<tt:value ref="$details.matnr"/>
</MATERAIL>
</tt:s-cond>
<!--Quantity -->
<tt:s-cond check="not-initial($details.tiq)">
<TIQ>
<tt:value ref="$details.tiq"/>
</TIQ>
</tt:s-cond>
<!--Packing Slip -->
<tt:s-cond check="not-initial($details.packing)">
<PACKINGSLIP>
<tt:value ref="$details.packing"/>
</PACKINGSLIP>
</tt:s-cond>
<!--Reading Serial Number Details -->
<tt:loop name="serial" ref="$ref.serial">
<THU_CONF>
<!--Serial Number -->
<tt:s-cond check="not-initial($serial.sernr)">
<SERNR>
<tt:value ref="$serial.sernr"/>
</SERNR>
</tt:s-cond>
</THU_CONF>
</tt:loop>
</SHIPMENT_CONF>
</DESPATCH_CONF>
</tt:loop>
</DESPATCHADVICE>
</tt:loop>
</tt:template>
</tt:transform>
We are reading the data from XML..Please suggest.. Please let me know how to use <tt:group>
Edited by: Sreedhar841 on May 27, 2010 4:09 PM -
Debugging Simple transformation program
can i know how to debugg a simple transformation program
Number of ways
When in SE80, and executing by a Tran Code, one of the options is to run in Debug mode.
Another is to set a break point in the program and then run it. It will stop at the break point IF it gets there
Yet another is once a program is running and is stopped at a screen, use /H in the transaction field in the Top Left area of
every screen (unless you have it shut off). -
IDOC Via Reprot program ( conversion)
Dear All,
I have to develop a conversion through IDOC Via Reprot program
Can any one please give a little idea how to do this.
Cheers,
Raadha.Reviving an old thread...
I'm getting a similar error making RFC calls from a stand-alone program to an ABAP server using JCo:
RFC_GET4, GET_ID-3c05 LINE 990
Any ideas?
Thanks.
Tim -
Copy transformation files, conversion files through UJFS
Hi,
I know it is possible to download transformation files or conversion files from UJFS from one application(say App1)/environment (Dev) and can be uploaded the same into another application(App2)/environment(QA)
But is it safe to do that way? any possible consequences anticipated?
Thoughts/inputs appreciated.
RegardsHi,
Transformation files maps the data file uploaded by you viz., conversion file. You can download or upload transformation file and canuse it in any other application also. It doesnot have any consequences in doing so.
Hope this helps.
Rgds,
Poonam -
Error occured while deserializing simple transformation program
Hi,
In the SOA Manager( In the CRM PRD system ), when I check the payload trace, the Request is blank and in the Response I find that there are few exceptions
1) CX_SY_CONVERSION_DATA_LOSS: XSLT exception - An error occured while deserializing the simple transformation
Data loss occured when converting ...
How do I know what was the input provided by the user and how to I use the transformation generated and identify the cause of the problem. in the PRD system What is the use of XSLT transformation?
Thanks,
Chakram GovindarajanHello Chakram,
We are facing the same issue , but in GRC & Remedy Integration.
Will you please let me know what did you do to resolve this issue if it has got resolved ??
Thanks in advance.
Regards,
Victor -
Desktop to socket programming conversion problem?
i have a Online desktop application.
i want to convert in Socket programming for Efficiency and Quick response.
i successfully connect client to server and server to client its work well.
now problem is that i had in application different type of objects , Database quires results, some Business class and other needed class.
how i pass these thinks to server to client and vice versa and distinguish them?I am very THANK Full for your Efforts
i locked my xml file succssfuly; but i still got same exception
locking a file code
Initializing streams
try {
is = new ObjectInputStream(clientSocket.getInputStream());
os = new ObjectOutputStream(clientSocket.getOutputStream());
fs = new FileOutputStream("first.xml");
BufferedOutputStream br = new BufferedOutputStream(fs);
xml = new XMLEncoder(br);
} catch (IOException e) {
System.out.println(e);
Locking a file it display file is locked
System.out.println("Trying to lock locked..");
fl = fs.getChannel().tryLock();
System.out.println("File locked..");
xml.writeObject(ud);
xml.flush();
fl.release();
System.out.println("lock released...");
fl.release();
is.close();
os.close();
xml.close();
clientSocket.close(); -
Conversion call in transformation files is not working
Dear Experts,
We are using BPC 7.5 NW SP06. For running master data load from BW, we are using the standard packages available. Whenever we are creating any transformation file keeping the conversion section blank it is working fine and getting validated. If we are creating new conversions, the same also gets validated and updated. To ascertain this, we also checked in the BW back end using UJFS t code and observed that the corresponding .CDM file is getting created in the back end. We are creating all such transformations and conversions in the default company folder. The issue lies in the fact that whenever we are referring the created conversion file in *CONVERSION section of the transformation file using the syntax:
ID/HIER_NAME = [COMPANY]Conversion.xls!CONVERSION
and trying validate the same we are getting the error:
**"xml(........................CDM) file doesn't exists or empty.
File / Document doesn't exist"*.
We again went back to UJFS and found the CDM file is intact there with proper conversion definition. We tried to validate the same phenomenon of calling a conversion using any other transformation file. But the same error happens every time although at the back end the .CDM file gets created.
What can be the problem here? We are stuck.
Your expert advise is highly aprreciated.
Thanks in Advance.Hi,
ID/HIER_NAME = COMPANYConversion.xls!CONVERSION
What is the file name here? Is it Conversion.xls and if it contains only one sheet then just try
ID/HIER_NAME = CONVERSION.xls
hope it works...
regards,
Raju -
Time offset in Conversion or Transformation
Hi Gurus
I have a question, I can generate time offset in conversions or transformation? for example a function to load data 2011 and that automatically be save as 2012, but dynamic, without script logic?
something like this
*MAPPING
TIME=TMVL(12, 0FISCPER)
thanks and
regards
Edited by: Nayadeth jeldres on Dec 5, 2011 10:52 PMAs far as i know , we can not use TMVL in transformation or conversion file. Its a script logic keyword
-
In a Conversion file, Using Java Script - IF statement with Greater,Less definitions
Hail to All Gurus,
Well, I've been trying to make a conversion file by using if statement of Java script with < , > definitions. unfortunately i got "Evolution error" over and over again.
Actually i want to convert all dates before 2009 as 2008.12. And the dates which is greater than 2009 will be converted as they are (e.g. 2009.01 or 2010.02 etc.).
Code is:
js:if(%external%.toString().substring(0,4)<"200900"){"2008.12"}else{%external%.toString().substring(0,4) + "." + %external%.toString().substring(4,6)}
SAP EPM version 10.0 SP15 Patch 2
Build 8586
Thanks for your help in advanceSadi,
You can write if Statement in transformation not conversion.
Look at this docs,
How to Import Master Data and Hierarchies into SAP BusinessObjects BPC 7.5 from SAP NetWeaver BW
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/c02d0b47-3e54-2d10-0eb7-d722b633b72e?QuickLink=index&…
Thanks -
Any program to active InfoSet at BW Production - BI 7.0?
Any idea for BI 7.0 , any idea how to active InfoSet under production machine?
For examples to active DataSource for production we will used :-
RSDS_DATASOURCE_ACTIVATE_ALL
Thanks in advance.
Edited by: Edi Erwan Abu Talib on Nov 11, 2008 8:38 AMHi check this link ..
transformation program RSQ_TRANSFORM_CLASSIC_INFOSETS.
http://help.sap.com/saphelp_nw04/helpdata/EN/ad/2225391d4f000be10000000a114084/content.htm
hope this helps
Regards ,
shikha
Maybe you are looking for
-
View photo folders not files in CS5 Bridge
How do I get back to the view of my photo folders? I can only see individual photo files, and not all of them now. Don't know what I did to make this happen. I have a 2009 iMac and CS5 Bridge (Adobe Creative Suite 5 Design Premium).
-
Never used iCal before and it is bewlidering to me.
Hi, I am trying to set up iCal so that I can remember to pay my bills by a specific date. I have read the help files but am still not quite getting it. What is the best entry to use for something like that? I thought it was something like a to do lis
-
Just google "Verizon Deleted "
I don't understand what is so difficult about this. Best Buy and Verizon, each in their own infinite wisdom, butchered my upgrade and account change 4 times. This has been ongoing for over a month now and I believe Verizon purposely drug out respondi
-
Thread producer/multiple consumer example!!
Hi, does anybody have an example of a procucer/multiple consumers thread example. I would like to do the following: -start one producer thread that writes data into an object. -start more consumer threads that read and process that data from that obj
-
hey guys how can i change the color inside a mask? i mean when i trace a mask with rectangle selection i have the yellow border and inside i hve in example the black color if i want to hide something how can i make the color inside in example white a