Read EDI-856 interface data in ABAP program
HI Experts,
I have a requirement to read the incomming EDI-856 interface data from ABAP program and generate an IDOC. I have gone through few EDI-856 documents and theformat in which to read the data .
Request you to let me know the code logic , function module to use or if you have any document which can help me in the development.
Thanks in advance
Regards
Santosh
Please help regarding
First could you please help me regarding the SCN search option?
please always try to attempt from your side if not able to solve than search in SDN finally you may land on SDN with thread.
Similar Messages
-
Passing data from abap-program to mssql database table thro native sql
Hi,
To pass the data from abap-program to mssql server,i have created database connection through dbco t.code.
now i am trying to get connection thro native sql but am not able to get it .Am working in ECC 5.0.
Could anyone help me on this.Did i miss anything?
i have tried Native-sql like this.
DATA: CON_NAME LIKE DBCON-CON_NAME VALUE 'BIW'.
EXEC SQL.
CONNECT TO :con_name AS 'C1'
ENDEXEC.
Thanks in advance.Hi,
Trying to do the same here, only using Oracle DB.
DATA: dbc TYPE DBCON_NAME VALUE 'BI'
TRY.
EXEC SQL.
CONNECT TO :dbc
ENDEXEC.
IF sy-subrc NE 0.
RAISE EXCEPTION TYPE cx_sy_native_sql_error.
ENDIF.
CATCH cx_sy_native_sql_error INTO oref_native_sql_error.
sql_emsg = oref_native_sql_error->get_text( ).
MESSAGE sql_emsg TYPE 'I'.
ENDTRY.
I keep getting the message 'Native SQL exception has occured' (because of the RAISE statement, I wonder how we can get a meaningfull error description).
Of course this can be a result of a number of network issues, so I'm trying to resolve this together with my BC admin.
I suggest the same to you..
In the meantime, if anyone can help out, it will be appreciated.
Regards,
SD -
Reading XML Data from ABAP Program?
Hi,
How do I read XML Data from an ABAP Program? For example if I have the below basic XML Code-
<xml>
<Name> Thiru </Name>
<Age> 24 </Age>
<City> chennai </Chennai>
</xml>
How do i read the data within the Name,Age, and City tags into variables in the ABAP Program?
Regards,
Thiruif you decide to do in XSLT, I have a sample list here:
XML file like this:
<?xml version="1.0" encoding="UTF-16"?>
<F>
<P1>
<t_1>value1</t_1>
<t_2>testvalue</t_2>
</P1>
<P2>
</P2>
</F>
XSLT file like this:
<xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sapxsl="http://www.sap.com/sapxsl" version="1.0">
<xsl:strip-space elements="*"/>
<xsl:template match="F">
<asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
<asx:values>
<<b>DOCUMENT</b>>
<xsl:apply-templates/>
</<b>DOCUMENT</b>>
</asx:values>
</asx:abap>
</xsl:template>
<xsl:template match="P1">
<ENTRY>
<<b>T_1</b>><xsl:value-of select="t_1"/></T_1>
<<b>T_2</b>><xsl:value-of select="t_2"/></T_2>
</ENTRY>
</xsl:template>
</xsl:transform>
ABAP program like this:
DATA: BEGIN OF wa_upload,
text(255) TYPE c,
END OF wa_upload,
itab_upload LIKE TABLE OF wa_upload,
BEGIN OF wa_document,
t_1 TYPE string,
t_2 TYPE string,
END OF wa_document,
itab_document LIKE TABLE OF wa_document.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = 'XXXXX'
filetype = 'ASC'
TABLES
data_tab = itab_upload.
CALL TRANSFORMATION zrappel_xml_test
SOURCE XML itab_upload
RESULT <b>document</b> = itab_document.
You should pay attention to the bold words.
hope it will be helpful
thanks -
How to read Production Order Long Text data in ABAP program
Hi friends,
I have the issue in reading the ' Long Text ' tab view data of production order
in CO03 transaction.Please can some body help me out to get this in ABAP program.
Regards,
Rajesh Akarteok goto the long text, double click it, or use the small pencil, so that you proceed to the text editor.
Once you are there, use the menu: goto->head
a small popup will come up, stating the information you need.
what you need is OBJECT, ID, Language and NAME.
with those information you can feed the FM READ_TEXT.
and woooohooo there you go -
How to get data in ABAP program from multicube in external BW system
Hi friends,
I want to get data from one multicube which resides in an external BW system, in my ABAP program internal table. Is there any SAP standard RFC / BAPI for this or is there any other way around or I have to design my own program to get the data ?
To make my requirement clearer, my ABAP program is in one BW box and the above mentioned multicube in another BW box. I want to get data from the multicube into my program.
Any help is appreciated with points.Look at the following FM; you may find the FM RSDRI_INFOPROV_READ_RFC useful.
Call the FM in your program and read data and update.
RSAD_INFOCUBE_READ_REMOTE_DATA
RSDRI_INFOPROV_READ_RFC
Ravi Thothadri -
PASS DATA FROM ABAP PROGRAM TO WORKFLOW CONTAINER
Hello Everybody,
I am a workflow beginner and I want to pass a data from my ABAP code to a workflow container. This workflow container is used in the Send Mail step.
The ABAP Program is:
REPORT zdb_work_flow.
tables : vbak.
DATA : k TYPE sweinstcou-objkey,
e TYPE swetypecou-event.
DATA : st TYPE swcont,
itab TYPE STANDARD TABLE OF swcont.
PARAMETERS : vbeln TYPE vbak-vbeln.
start-of-selection.
st-element = 'VBELN'. "This is my WORKFLOW CONTAINER
st-tab_index = 1.
st-elemlength = 10.
st-type = 'C'.
st-value = vbeln.
append st to itab.
k = vbeln.
e = 'TRIGGER' "This is an event in my BUS OBJ ZDB_WFLOW
CALL FUNCTION 'SWE_EVENT_CREATE'
EXPORTING
objtype = 'ZDB_WFLOW' "My BUS OBJ
objkey = k
event = e "Event TRIGGER in ZDB_WFLOW
tables
event_container = itab
exceptions
objtype_not_found = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF. .
COMMIT WORK.
Now I have created a workflow in SWDD as ZDB_WF_SW.
In this WF I have created a container as VBELN.
In the SEND MAIL I have given a header as "Worflow Triggered for &VBELN&"
PROBLEM.
The Workflow is getting triggered. I am also getting a mail "Workflow Triggered for" in my mailbox but the &VBELN& is missing from the header.
I have set the IMPORT EXPORT flag of the WF CONTAINER "VBELN"
Please Help.
Edited by: Deepankar.B on Feb 22, 2011 4:08 PM
Edited by: Deepankar.B on Feb 22, 2011 4:10 PMYou wouldn't use a SMA as an assistance class - but refer to one within it.
I would use Shared Memory Area classes - but I'd also build a SMA that could talk across multiple application servers.
Thomas Jung proposed this in a forum reply some time ago.
It shouldn't be too difficult to use RFC's to access the content of SMA's in multiple app servers - ensuring synchronisation across multi app servers. I've not yet had the need, so haven't attempted.
The long polling in 7.02 apparently uses this approach, so in a 7.02 system there may even be standard components/ SMAs that you could use.
I do not think global areas in FM's are available across sessions - I don't think you could use that as a data transport. -
Read an XML file into an ABAP program and manipulate it.
I would like to know if it is possible to do the following in an ABAP program:
1) Read an XML file into an ABAP internal table
2) Call an XSLT transformation on the source file and store the results in an ABAP table.
Is this possible to do? I have used ABAP XSLT in PI, but never in an ABAP program. I see you can use the CALL TRANSFORMATION command, but I have never used it in an ABAP program.
Kind Regards,
Tony.Check out these blogs.
XML DOM Processing in ABAP part I - Convert an ABAP table into XML file using SAP DOM Approach.
XML DOM Processing in ABAP part II - Convert an XML file into an ABAP table using SAP DOM Approach. -
Error in Posting Data Using ABAP Program.
I am Using Scenario SAP(RFC) to Webservice through XI
I called My RFC into ABAP Program and given RFC Destination
and executing it goes into Short DUMP.
I gives an Error message as
" alternativeServiceIdentifier:party/service from channel configuration are not"
Wat should i Do for this Error.
regards,
Jayasimha JangamHi
Please look into these threads
alternativeServiceIdentifier: party/service from channel configuration are.
Rfc sender problem(sap r/3 -se37) 'alternativeServiceIdentifier: party/serv
Also this Blog will help you,
/people/michal.krawczyk2/blog/2005/09/07/xi-why-dont-start-searching-for-all-errors-from-one-place
Reward points if found usefull............ -
Full Load and delta loads of HR Data using ABAP Program
Hi All,
I need to write an ABAP program that will pull some HR data from some of the infotypes.When i run it for the first time it should pull all the data for all the employees but in the subsequent runs it should run only the delta changes
for example
inital run is on 04/30 it should pull all the data for all the employees
next run 05/02 then it should pull onlly the infotypes for which there is a change between 04/30 and 05/02
Please let me know the solution
Thanks
Bala DuvvuriRob,
I understand that I need to AEDTM field but the problem is
during the initial load i will not have any control date stored in the z table so i will fetch all the records using the select queries on various infotypesin the if condition but the problem is i need to repeat the same queries by adding the AEDTM condition in the else condition where control date is not initial(not an initial load) so it will be a duplicacy of all the select queries.
is it a good programming style?please let me know your thoughts on this
if p_ctrl is initial " Initial load
select queries
else " subsequent runs
same select queires with AEDTM condition
endif.
Thanks
Bala Duvvuri -
Updating Q and P table of master data using ABAP program
Hi All
I have a requirement to update Q and P table(non key and non date fields) of master data using an ABAP program.
Is this something recommended?
Will there be any issues if I do that?
Thanks
DeepakThanks Vikram. Ok. My look up is on some other master data Q table and that is the reason why I asked about ABAP custom program.
Look like I will have to do the following approach.
Load the required supporting master data to BW.
Execute Attribute change run process for those master data objects.
Load the actual master data and look up on supporting master data.
Execute attribute change run process.
This process takes me long time and I am trying to reduce the overall execution time. let me know if you have some good suggestions.
Thanks
Deepak -
Import data from ABAP program to Excell template file
Hello everyone
I have a such task: In abap program I have fields(screen fields), which I want to import into excell file. I don't want to export into empty file but into ready template .xls. Is there any possibility to match corresponding fields?
I really need to know, I will be gratefully for any suggestions.
GreetingsHi Katarzyna ,
something like
DATA: EXCEL TYPE OLE2_OBJECT.
DATA: BOOKS TYPE OLE2_OBJECT.
DATA: BOOK TYPE OLE2_OBJECT.
DATA: CELL TYPE OLE2_OBJECT.
DATA: FONT TYPE OLE2_OBJECT.
DATA: FILE TYPE OLE2_OBJECT.
CREATE OBJECT EXCEL 'EXCEL.APPLICATION'.
CALL METHOD OF EXCEL 'WORKBOOKS' = FILE.
CALL METHOD OF FILE 'OPEN' EXPORTING #1 = P_FILE
#2 = 1.
CALL METHOD OF EXCEL 'CELLS' = CELL EXPORTING #1 = P_LINE
#2 = P_COLUMN.
SET PROPERTY OF CELL 'VALUE' = P_VALUE.
CALL METHOD OF EXCEL 'QUIT'.
This is just a compilation from a complex program. Do some modularization (i.e. create FORM fill_cell using P_line P_column P_value...)
Hope I did not forget anything. Meanwhile we have much more modern and advanced methods and classes - this one is of 2000 (Release 4.5?).
Regards,
Clemens -
Read the intial version of an ABAP Program
Hi,
I need to download the first and the last version of an ABAP Program into a flat file. I used the "read report" statement and download the current active version of the program which is the last version but I need the initial version of the program too.
If we need to use one of the below function modules what would be the parameters to be passed into them,
SCWB_GET_ABAP_CODE_OF_OBJECT
RS_DETERMINE_OBJECT_SOURCE.
Please advise.
Regards,
Prabaharan.GHi,
I tried passing the version number as 1 but though the function module does not give "no versions" message, it does not give any entries in the internal tables.
Could you please try it once and let me know the results.
Regards,
Prabaharan.G -
Read dimension member(master data) to ABAP internal table in BPC 10.0 NW
Hi all,
I manage to read transaction data using this example [replacement for IF_UJ_MODEL~GET_APPL_DATA;
I am now trying to read members(master data) from a dimension to a ABAP internal table but I have no idea how to.
Can anyone advise me on how to read members(master data) from a dimension to a ABAP internal table.
Some sample code would be really appreciated.
Regards
Edited by: HK Kang on Jan 3, 2012 4:26 AMHi Chanaveer,
UJD_ADMIN_RUN_OPTIMIZE can be used only for executing the FULL & LITE OPTIMIZER packages.
Looking at the code of UJD_RUN_OPTIMIZE_PACKAGE it seems this FM can be used to trigger process chain from BW.
Please refer below link on SDN showing how to load Master Data on FLY in SAP BPC 10.
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/2020b522-cdb9-2e10-a1b1-873309454fce?QuickLink=index&overridelayout=true
Thanks,
Rohit -
Checking Posting Date in ABAP Program
Dear All,
I am given a requirement to develop a program to create PO without using Tcode ME21N.
I find trouble in validating posting date.
How to check that the entered date is the valid posting date or in which table i can get the values to check.
I tried the following FMs, but couldn't find the solution.
ACEPS_OPEN_PERIOD_DETERMINE
FC_CHECK_PERIOD_OPEN
G_PERIOD_ALLOWED_CHECK
FI_PERIOD_CHECK
DETERMINE_PERIOD
Could anybody help me in this regard.
Best Regards,
S.SridharHi,
Use the following FM :
FM_INPUT_CHECK_POSTING_DATE
FCJ_CHECK_POSTING_DATE
Regards,
Mansi. -
Reading BLOB in Native SQL from ABAP program
Hello,
I'm trying to read content of a BLOB field from a table with Native SQL in ABAP like this:
DATA: l_bytes type xstring.
EXEC SQL.
SELECT bytes INTO :l_bytes FROM tablename
ENDEXEC.
But when I'm using xstring it returns only 32768 bytes. When using type x length 65000 for l_bytes it returns 65000 bytes, but x is limited to 65535 bytes only. So why it returns only 32768 bytes in direct sql? For DB2 I found note 610342 where you need to add \lob to the statement, I tried with Oracle but doesn't work.
DATA: CLOB_VAR TYPE STRING.
DATA: BLOB_VAR TYPE XSTRING.
EXEC SQL.
SELECT FCLOB, FBLOB FROM ZZTAB INTO :CLOB_VAR\lob, :BLOB_VAR\lob
ENDEXEC.
Regards
MarkusHi Markus,
you have to read it in chunks (remember a blob could be up to 4 Gbyte!).
I assume you store the byte stream in the field (no bfile pointer to a file ).
Give you a pseudocode that you get the picture.
Would recommend that you read the Oracle manual (db Version?)
9i
http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96612/d_lob2.htm#1008611
10g
http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_lob.htm#ARPLS600
chunksize = 32768 . " or use 65000 . This is the amount of the blob part you want to read
offset = 1.
*get the row of interest and retrieve blob's length
Exec sql.
select dbms_lob.getlength(your_blob) :blob_length from blob_table where my_primary_key = 1
end exec.
*calculate times to read from blob until the end (well, leave the adjustment to you
* in case of an uneven fraction)
ntimes = blob_length / chunksize .
Do ntimes
*loop and get the chunks into your variable:
* start reading from offset chunksize of bytes
exec sql.
select dbms_lob.substr(your_blob, :chunksize,:offset) into :xblobvar from blob_table
where my_primary_key = 1
endexec.
*don't know what you want to do with the blob chunk...
*process :xblobvar
offset = chunksize * ntimes .
enddo.
bye
yk
Maybe you are looking for
-
Add Doc. Date to "Customer Receivables Ageing" report
Hi! Let me know if you can in the PLD layout called "Business Partners Aging (Details) (System)" show instead of the Posting Date the Doc. Date. Thanks!
-
hi can some one brief me about business objects ?Im very new to this and what basic knowledge we need to have? what exactly is bob and hw to get them in to bi? Regards, Smitha
-
Dump in Service orders in Portal ????
Hi Experts !!!!!!!!! I m working on Service scenario (Service orders) i have made some changes in my standard iview of Serivce order after doing it i have also generated layout for related field group but when i execute same application thruough MAC
-
New Iphone 4s - failure trying to redeem gift card on itunes
I receive a message that says I need to update security info under my info page...I click update security info...the mext message states "cannot open page" safari cannot open the page because it could not establish a secure connection to the server.
-
How to run FNDMLSUB - Multiple languages - from PL/SQL
Hi, i would like to submit a FNDMLSUB program (Multi Language request submission) from PL/SQL (need to print multiple invoice programs at once, there is no MLS support for request sets). What's the pl/sql procedure for submission? I can submit it, bu