Batch Input in RFC function module
Hi,
I am creating a function that change the location of an equipment in transaction IE02. When i execute this function from SAP it works fine, but when its call from .Net connector does not work, no changes to equipment are realized. i am using call transaction to generate a batch input mode.
i have used submit to programs with the necessary code to execute call transaction IE02 but the results are the same.
How can i execute a batch input from rfc funtion module?
thanks,
Alejandro
Message was edited by: Alejandro López
Alejandro,
Tengo problemas similares con una rfc y batch input.
Serías tan amable de enviarme el código de la rfc para revisar, chequee los permisos pero igual no actualiza datos.
Gracias.
Similar Messages
-
Backgroung job failing becuase RFC function module is running in Dialog
Hi,
I have a program which is calling a RFC function module. I am running this program in background as a job. Now this function module which is in other system is running in Dialog and giving a time out error and the job is failing becuase of that.
I tried call fucntion 'test' in background task
destination 'XVZ'
tables
test = 'test'.
But this is not working, i can still see this function module running in Dialog in SM50. Any suggestion?
Thanks,
ShwetaHi !
RFC-Called function-modules are running in a dialog workprocess of the
target system (they could not run in a batch proecess !!).
That means the do have the same "Timeout" limitations than any other
Dialog-Process.
What you can do:
- The Dialog "Timeout" could ce increased by your SAP-BASIS
- If they could not - you should "shorten" the LUWs in the target-funktion.
...means - put a COMMIT WORK an any point the work is done.
After a COMMIT WORK the "Timeout" Counter beginns at 0 !
Hope that helped....
Reward points would be nice... -
Unknown error calling a RFC Function Module in BODI
Hi all,
I am having an issue identifying the error that my batch job in BODI is giving with regards to a RFC function module call in my query. The value returned by the standard parameter 'AL_RFC_RETCODE' are square characters ( ).
At the completion of the job, the error message 'RFC CallReceive error <Function ZCT_INDSLS_SLS_TRN_INSERT: Invalid request.. Invalid request.>.' is being output.
Correct me if I'm wrong but the parameter 'AL_RFC_RETCODE' should return standard values as per the techical manual provided to undertand any errors that might occur during a RFC FM call.
Can anyone help me on this?
Best regards,
Andrew WongHi Senthil,
I think you answered your query in your question itself
The user ID and password need to be maintained in RFC destination in SM59.
Go to SM59 and then click on test connection..if it does not ask for ID and passwoed that means correct ID and password is maintained in SM59 otherwise maintain it.
Regards,
Atish -
Collection problem with RFC function module WSDL.
Hi.
I have developed an RFC function module in a SAP system version 4.7 (WAS 620). This FM has 2 table parameters. I have no problem when I see the WSDL in the SAP Web Service Browser.
Another team is trying to consume this RFC FM as a web service from a Java application but they say they can't see the table parameters as collections.
Here is the WSDL of the FM, the table parameters are T_MOVIM and T_ERROR:
<?xml version="1.0" encoding="UTF-8" ?>
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:s0="urn:sap-com:document:sap:rfc:functions" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="urn:sap-com:document:sap:rfc:functions">
<types>
<xsd:schema targetNamespace="urn:sap-com:document:sap:rfc:functions">
<xsd:element name="ZMMFUSAPTK_0001">
<xsd:complexType>
<xsd:all>
<xsd:element name="GENIDOC" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="1" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="T_ERROR">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="item" minOccurs="0" maxOccurs="unbounded" type="s0:ZMMTASAPTK_0012" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="T_MOVIM">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="item" minOccurs="0" maxOccurs="unbounded" type="s0:ZMMTASAPTK_0011" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:all>
</xsd:complexType>
</xsd:element>
<xsd:element name="ZMMFUSAPTK_0001.Response">
<xsd:complexType>
<xsd:all>
<xsd:element name="CODRET">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="1" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="T_ERROR">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="item" minOccurs="0" maxOccurs="unbounded" type="s0:ZMMTASAPTK_0012" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="T_MOVIM">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="item" minOccurs="0" maxOccurs="unbounded" type="s0:ZMMTASAPTK_0011" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:all>
</xsd:complexType>
</xsd:element>
<xsd:complexType name="ZMMTASAPTK_0011">
<xsd:sequence>
<xsd:element name="REFERENCIA" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="FECHACONT" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="8" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="FECHADOC" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="8" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CODMOV" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="2" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="NROPLAN" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="12" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="NROCOMP" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CLASEMOV" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="3" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CENTRO" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="4" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="ALMACEN" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="4" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="MATERIAL" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="5" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="LOTE" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CANTIDAD" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="15" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="MOTIVOMOV" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="4" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CENTROREC" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="4" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="ALMACENREC" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="4" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CENTROCTO" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="ORDEN" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="12" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="TIPOSTK" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="1" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="NROPEDIDO" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CODCISTERNA" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="50" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="ZMMTASAPTK_0012">
<xsd:sequence>
<xsd:element name="REFERENCIA" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="CODERR" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="3" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="MSJERR" minOccurs="0">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="100" />
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
</types>
<message name="ZMMFUSAPTK_0001Input">
<part name="parameters" element="s0:ZMMFUSAPTK_0001" />
</message>
<message name="ZMMFUSAPTK_0001Output">
<part name="parameters" element="s0:ZMMFUSAPTK_0001.Response" />
</message>
<portType name="ZMMFUSAPTK_0001PortType">
<operation name="ZMMFUSAPTK_0001">
<input message="s0:ZMMFUSAPTK_0001Input" />
<output message="s0:ZMMFUSAPTK_0001Output" />
</operation>
</portType>
<binding name="ZMMFUSAPTK_0001Binding" type="s0:ZMMFUSAPTK_0001PortType">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" />
<operation name="ZMMFUSAPTK_0001">
<soap:operation soapAction="http://www.sap.com/ZMMFUSAPTK_0001" />
<input>
<soap:body use="literal" />
</input>
<output>
<soap:body use="literal" />
</output>
</operation>
</binding>
<service name="ZMMFUSAPTK_0001Service">
<documentation>SAP Service ZMMFUSAPTK_0001 via SOAP</documentation>
<port name="ZMMFUSAPTK_0001PortType" binding="s0:ZMMFUSAPTK_0001Binding">
<soap:address location="http://dbades00.bue.bemberg.com.ar:8002/sap/bc/soap/rfc" />
</port>
</service>
</definitions>
Should I change something in the definition of the parameters of the FM? or the problem is with the parsing process on the other system?
Thanks in advance.
Fabian.Welcome to SDN.
I am not sure about this particular issue, but i have used WSDL from WAS6.20 system in MS Office infopath to consume webservice where we have had table parameters without any issue.
may be try with office infopath to make sure that the problem is with the WSDL or with the java application.
Regards
Raja -
hi
am created a rfc functional module program(se37) which receives the two input value from calling program and just add and it returns to the calling program(se38).
the program is executed successfully but the probs is the rfc functional module does not print it executable contents. the calling program does print its executable contents.
PLZ RESOLVE THIS PROBLEM
see the calling program and rfc functional module below
REPORT YSUSEX51.
PARAMETERS : I1 TYPE I ,
I2 TYPE I,
DEST1 LIKE RFCDES-RFCDEST DEFAULT 'NONE'.
DATA: RESULT TYPE I,
SYSTEMID TYPE SY-SYSID.
CALL FUNCTION 'Y_RFCMODULE' DESTINATION DEST1
EXPORTING
A = I1
B = I2
IMPORTING
C = RESULT
SYS = SYSTEMID
EXCEPTIONS
INVALID_DATA = 1
COMMUNICATION_ FAILURE = 2
SYSTEM_FAILURE = 3.
CASE SY-SUBRC.
WHEN 1.
WRITE: / 'NO DATA AVAIL'.
EXIT.
WHEN 2.
WRITE:/ 'CONNECTION COULD NOT BE ESTABLISHED'.
WHEN 3.
WRITE : / 'SYSTEM NOT AVAIL'.
EXIT.
ENDCASE.
WRITE:/ 'INSIDE THE CALLING MACHINE'.
WRITE: / RESULT.
WRITE: / SYSTEMID COLOR 7.
IN THE RFC FUNCTIONAL MODULE IT DOES NOT PRINT THE A ,B,C AND SYS VALUE,
FUNCTION Y_RFCMODULE.
""Local Interface:
*" IMPORTING
*" VALUE(A) TYPE I
*" VALUE(B) TYPE I
*" EXPORTING
*" VALUE(C) TYPE I
*" VALUE(SYS) LIKE SY-SYSID
*" EXCEPTIONS
*" INVALID_DATA
WRITE: /'INSIDE THE REMOTE SYSTEM'.
WRITE: / A.
WRITE: / B.
C = A + B.
SYS = SY-SYSID.
WRITE:/ C.
WRITE: / SYS COLOR 7.
ENDFUNCTION.
REGARDS
surenderHi
Instead Of giving write statement inside a function module
write these statement where this rfc is called.
if rfc connection is established ,then
number will be printed.
otherwise not.
Dont forget to reward points
Edited by: neetu chhabra on Mar 10, 2008 12:14 PM -
Call RFC Function Module and return 1000 records at a time
I would like to call a Remote Enabled Function Module from a non SAP system. This function module will select data from the database and return it to the calling program.
Suppose there are 100,000 records that need to be returned, but the calling module would like the data in chunks of 1000 records. Therefore the calling program would call the FM 100 times.
How do I code the function module to know on each subsequent call to grab the next chunk of 1000 records?
Let me know if additional information is needed.
Thanks,
AaronHello,
Here is how you can go for this issue:
1. Create one RFC function module with following parameter. These parameters are with respective of chunking logic.
Import: Package Size
Export: Total number of records
Changing: chunk count
Implement following logic:
1. First of you need to know how many chunks you need to fetch for that get the count of total number of records. This is one
time activity so you better maintain one flag import parameter will be set to 'X' only first call.
2. Get the number of chunk using total number of records / chunk size for e.g. 1000 / 100 so chunk count = 10.
3. Define internal chunk counter in function module which will be used to locate the correct chunk depending on the chunk
counter value sent from calling program.
4. Send first call with package size 100 and chunk count = 1, execute select statement and increment internal
chunk count check if chunk count = internal chunk count in current case chunk count = 1 so exit select statement and return
with first chunk.
5. Send second call with package size 100 and chunk count = 2. Execute select statement and check chunk count with internal
chunk counter, in current case it will be 1 so skip that data and go for next chunk of 100 records increment internal chunk
counter. In this case it will match with external chunk count = 2. load output table with that data and return to calling program.
6. Repeat step 4 until you reach last chunk.
You need to use SELECT...ENDSELECT with PACKAGE SIZE addition so for every loop it will return number of records mentioned in package size.
Hope this helps.
Thanks,
Augustin. -
How to log input parameters for Function Modules?
Hi,
I need to create a Logging system to trace input parameters for function modules.
The log functionality could be done by developing a class method or a function module (For example 'write_log'), and calling it within each function module that I want to log. The 'write_log' code should be independent from the interface of the Function Module that I want to log.
For example, I'd like to write a function/class method that can log both these functions modules:
Function DummyA
Input parameters: A1 type char10, A2 type char10.
Function DummyB
Input parameters: B1 type char20, B2 type char20, B3 type char20, B4 type Z_MYSTRUCTURE
Now the questions...
- Is there a "standard SAP" function that provide this functionality?
- If not, is there a system variable in which I can access runtime all parameters name, type and value for a particular function module?
- If not, how can I loop at Input parameters in a way that is independent from the function module interface?
Thank you in advance for helping!check this sample code. here i am capturing only parameters (import) values. you can extend this to capture tables, changin, etc.
FUNCTION y_test_fm.
*"*"Local Interface:
*" IMPORTING
*" REFERENCE(PARAM1) TYPE CHAR10
*" REFERENCE(PARAM2) TYPE CHAR10
*" REFERENCE(PARAM3) TYPE CHAR10
DATA: ep TYPE STANDARD TABLE OF rsexp ,
ip TYPE STANDARD TABLE OF rsimp ,
tp TYPE STANDARD TABLE OF rstbl ,
el TYPE STANDARD TABLE OF rsexc ,
vals TYPE tihttpnvp ,
wa_vals TYPE ihttpnvp ,
wa_ip TYPE rsimp .
FIELD-SYMBOLS: <temp> TYPE ANY .
CALL FUNCTION 'FUNCTION_IMPORT_INTERFACE'
EXPORTING
funcname = 'Y_TEST_FM'
* INACTIVE_VERSION = ' '
* WITH_ENHANCEMENTS = 'X'
* IGNORE_SWITCHES = ' '
* IMPORTING
* GLOBAL_FLAG =
* REMOTE_CALL =
* UPDATE_TASK =
* EXCEPTION_CLASSES =
TABLES
exception_list = el
export_parameter = ep
import_parameter = ip
* CHANGING_PARAMETER =
tables_parameter = tp
* P_DOCU =
* ENHA_EXP_PARAMETER =
* ENHA_IMP_PARAMETER =
* ENHA_CHA_PARAMETER =
* ENHA_TBL_PARAMETER =
* ENHA_DOCU =
EXCEPTIONS
error_message = 1
function_not_found = 2
invalid_name = 3
OTHERS = 4
IF sy-subrc = 0.
LOOP AT ip INTO wa_ip .
MOVE: wa_ip-parameter TO wa_vals-name .
ASSIGN (wa_vals-name) TO <temp> .
IF <temp> IS ASSIGNED .
wa_vals-value = <temp> .
ENDIF .
APPEND wa_vals TO vals .
ENDLOOP .
ENDIF.
ENDFUNCTION. -
Using RFC Function Module to send data to NON SAP Application
Hi friends,
Please guide me how can I send data from SAP -> Dotnet Applcation using Dotnet Connector through RFC function module from SAP side. In my scenerio, I Run Z transaction to executte RFC function module which create some data to pass to dotnet connector.
Regards,
Rajesh KumarHi,
You can make use of Dotnet connector to read the content of SAP RFC .. (eaiest of all)
The RFC can be executed using connector , and can read the data simultaneously.. u need to code in dotnet for this..
else create a webservice and read it from dot net ..
Regards
Renu Gusain
Edited by: Renu Gusain on Jan 25, 2010 12:55 PM -
How to debug a RFC function module remotely from another R/3 system?
Hi experts,
I have RFC function module in one R/3 system. I am calling this from another R/3 system that is cross apps (Xapps).
This function module is Synchronous.
Is it possible to debug this function module from cross apps?
Can somebody give me the steps?
Thanks & Regards
GopalHi Shree,
Can you explain it bit more?
Do I have to call the function module with "IN BACKGROUND TASK"?
Or is it that I have to just put external breakpoint in the function module?
Please help
Thanks
Gopa -
Is it possible to call custom designed RFC function module, apart from BAPI
Hi Friends,
1. Is it possible to call custom designed RFC function module, apart from BAPI.
2. Why we call it Adaptive RFC layer, Since every time the JCO layer updated with SAP, Why cant be dynamic.
Thanx for Ur time.
Cheers,
SamAlso check <a href="http://help.sap.com/saphelp_nw04/helpdata/en/41/38bc8f813719488ddc9d9b21251ec3/frameset.htm">here</a> for more information on aRFC. Here you can find why it is called adaptive.
Regards,
Christophe -
Problem while calling an RFC Function Module in Background
Hello,
I have created a RFC function module for reading data from an external DB system. The FM calls an external RFC program (coded in C++ using RFC SDK), which delivers the required data. This external program is maintainged as an TCP RFC Connection in SM59.
Further I have created a report, that calls the RFC function module to get the data from the external RFC programm.
My problem is, when I call the report in foreground, everything works OK, the RFC connection works and data can be read from the external program.
However, when I schedule the report to run in background as a job, the report is stating in the protocoll that there was a problem calling the defined RFC connection (although the connection is working properly at that time).
More funny is, this particular problem with running in background occurs only in the productive system, in test and development system the report works correctly also while running as a job in background.
Can you suggest the solution to this problem? Could it be something with authorisations or server settings?
I will be on holiday for the next 6 weeks, so take your time to answer .
Regards,
Dusan.
Edited by: Julius Bussche on Jan 22, 2009 7:19 PM
Please read the forum rules about u r g e n t ...This is an external RFC server program, not a remote enabled ABAP RFC function module as the others seem to be assuming, right?
Is it possible that your DEV and QAS systems only have one application server, but the PROD has many and dedicated one(s) for processing low priority background jobs?
It might be that the target server of your TCP connection is not this BTC instance, and your RFC server is returning the data "locally" - so, into nirvana...
Just guessing, but might be worth checking.
Cheers,
Julius -
Problem with RFC function module from R/3 to CRM
Hi, i have a RFC function module created in R/3, this is the code:
function Z_CRM_PRODUCTO_INTERLOCUTOR.
""Interfase local
*" IMPORTING
*" VALUE(GV_VKORG) TYPE VKORG
*" VALUE(GV_VTWEG) TYPE VTWEG
*" VALUE(GV_MATNR) TYPE MATNR
*" VALUE(GV_KUNNR) TYPE KUNNR_V
*" EXPORTING
*" VALUE(GV_KDMAT) TYPE MATNR_KU
*" VALUE(GV_POSTX) TYPE KDPTX
*" EXCEPTIONS
*" NOT_FOUND
UNPACK GV_MATNR TO GV_MATNR.
UNPACK GV_KUNNR TO GV_KUNNR.
select single KDMAT POSTX
into (GV_KDMAT, GV_POSTX) from KNMT
where VKORG = GV_VKORG
and VTWEG = GV_VTWEG
and KUNNR = GV_KUNNR
and MATNR = GV_MATNR.
IF sy-subrc <> 0.
RAISE NOT_FOUND.
ENDIF.
endfunction.
When i call this function from CRM, i do it like this:
CALL FUNCTION 'Z_CRM_PRODUCTO_INTERLOCUTOR'
DESTINATION LV_RFCDEST
EXPORTING
GV_VKORG = lv_vkorg
GV_VTWEG = ORGMAN_H-DIS_CHANNEL
GV_MATNR = ORDERADM_I_WRK-ORDERED_PROD
GV_KUNNR = WA_DATOS_PER-N_PAGADOR
IMPORTING
GV_POSTX = IT_POS_LINE-DESCRIPCION
GV_KDMAT = IT_POS_LINE-material
EXCEPTIONS
not_found = 1.
where:
it_pos_line-descripcion type string
it_pos_line-material type string.
Well, my problem is that when debugging, in R/3 the 2 return values have the correct value, but when they are passed to CRM they have only one position.
As i've been told, it was working ok, but it's being wrong since we made a ¿conversion to unicode?. Maybe I should change the type of return ???
Thanks in advance !!!Hello Maria,
Make sure you define your parameters in CRM exactly the same way as in R3, do not use type string here.
So:
it_pos_line-descripcion type C char 40,
it_pos_line-material type C length 35.
Kind regards,
John. -
Debugging RFC function module from ECC to CRM
Hi All,
My requirement is to debug an RFC function module present in CRM(7.0) system from ECC(6.0) system. A report program in ECC will call CRM custom FM. I found many posts in SDN with the same issue and tried to implement suggestions provided there. But I couldn't succeed. The approach I followed is:
I logged in to ECC report program and kept an external breakpoint just before the function module call.
I logged in to CRM system, opened the function module and kept an external breakpoint there.
In both the systems I provided the dialogue userid( id through which I log in to SAPGUI) in the system->settings->debugging option.
In CRM I activated the external break point in transaction SRDEBUG.
Now when I execute the report program in ECC, control stops at the breakpoint. If I press F5 at the function call, control is not going to the external break point set in the CRM FM. I am getting output of FM directly.
I tried with different settings like turning on the check box for IP matching and session breakpoint active immediate, switching to classic debugger etc. I also tried to provide the RFC user id instead of dialogue user but system throws exception saying only dialogue userids are allowed. I found that by inserting an infinite loop statement, control goes inside the RFC CRM FM but I prefer not to change the code.
Please let me know if I missed anything.
Thanks and Regards,
NarenHi,
Debug RFC calls
When an RFC function module is called it is usually not possible to debug the call, using the below techniques we can achieve the same. For this example we are calling an RFC enabled FM in ECC system from CRM system.
Scenario 1: Calling a custom RFC FM
STEP 1: Add an infinite loop in the remote custom Function Module (adding a u201CDO. ENDDO.u201D statement at the start of the FM would be enough).
STEP 2: Execute your program in the CRM system. The execution stops at the RFC call, because of the infinite loop.
STEP 3: Now login to the ECC system and go to transaction SM51 select the process which is executing the RFC and navigate to the menu: u201CProgram/Session->Program->Debuggingu201D this triggers the debugger session in a separate window.
Scenario 2: Calling a Standard RFC FM
When we are debugging a standard program we cannot add the infinite loop, hence we cannot go to SM51 and debug the work process. The RFC destination for the ECC system has a User specified, the RFC function module gets executed using this users credentials. Usually the basis team set up the RFC user as non Dialog user, this does not allow debugging. Contact your Basis team and get this changed to a dialog user enabling you to debug RFC function calls via the normal debugger.
Note: User name configured in the RFC destination (transaction SM59)
Note: User type for the RFC User (transaction SU01D)
Hope this will be helpful.. -
Hello Guys,
I have a question regarding calling a RFC function module.
In BW - BI 7.0 I call a RFC function module:
(The ABAP program in BW-BI 7.0 is below)
CALL FUNCTION ''ZTESTFUNCTIONMODULE' " Function module in ECC
DESTINATION 'DECCLNT110' " ECC system
TABLES
it_gl_item = it_gl
it_errlog_gl = it_errlog_gl.
The 'ZTESTFUNCTIONMODULE' is RFC enabled in the ECC system.
The purpose is we retarct the data from BW to ECC.
When I run the function module it always asks for the user id and password.
The SAP logon screen appears and it asks for the user id and password.
The destination is maintained in the SM59 transaction and also the user is maintained there. I think it should login automatically into remote system and return the tables. is it correct. How to skip the logon screen.
Do I have to pass the user id and password in the function module. I think it should take the user id from the SM59 destination. Is it correct.
Please advise. As always thanks for your help guys.Hi Senthil,
I think you answered your query in your question itself
The user ID and password need to be maintained in RFC destination in SM59.
Go to SM59 and then click on test connection..if it does not ask for ID and passwoed that means correct ID and password is maintained in SM59 otherwise maintain it.
Regards,
Atish -
Error when call RFC Function module in R/3
Dear All,
We are trying to call RFC function module CBIF_GLM1_PROCESS_ORDER_READ (This is not a BAPI and also not released ) in R/3 from XI system.
we are facing the error "Error while lookup Exception during processing the payload. Error when calling an adapter by using the communication channel CC_PPPI_MES_RFC_Rcvr (Party: , Service: WCD_320, Object ID: 16563889b449328eac76caa6a3bc592e) XI AF API call failed. Module exception: 'error while processing the request to rfc-client: com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.adapter.rfc.core.client.RfcClientException: failed to parse BAPI response due to: com.sap.aii.adapter.rfc.util.bapi.BapiException: Parameter with name RETURN not found.'. Cause Exception: 'com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.adapter.rfc.core.client.RfcClientException: failed to parse BAPI response due to: com.sap.aii.adapter.rfc.util.bapi.BapiException: Parameter with name RETURN not found.'."
This is the first time we are doing this configuration.
Could you please let me know what woulbe the reason.read the original message
We are trying to call RFC function module CBIF_GLM1_PROCESS_ORDER_READ (This is not a BAPI and also not released ) in R/3 from XI system.
I am talking about the above Receiver RFC channel which you guys are using to call R/3 from XI. That where you need to change the commit parameter
Maybe you are looking for
-
Leopard froze at the middle of installation and now mbp won't start
I first tried to install Leopard by upgrade mode but it froze after the dvd verification so I restarted it and no problem, the second time I tried Erase and install mode, and in the middle of the installation process it froze, there were 41 minutes l
-
I'm trying to apply a logo graphic to a photo?
I'm brand new to Adobe Photoshop Elements and also not very handy with computers.... I can't figure out how to add my logo to my photos, any help would be much appreciated?
-
How to display html content with image in Adobe Flash and Flex mobile project?
Hi, I have a html content with image in it. How to display it in Adobe Flash Builder and Flex mobile project? Which control needs to be used for this?
-
How can I make the current date/time be sent when emailing as XML?
I'm creating a form for a customer to use for submitting print jobs. This customer will be emailing the XML form data, which will in turn be converted into a production order. I'd like to make the PDF form capture my customer's system time, so that I
-
Getting wife a new iphone..backup questions
Not too good in using itunes. My wife has an iphone and my limit to itunes is putting some songs on my ipod. I want to surprise my wife with a new iphone this week and before I get her a new one I want to make sure I save all of her content and mos