How to debug RFC connection using RfcOpenEx?
Hi,
I use COOPC1 to test a RFC connection and this transaction uses RfcOpenEx which fails.
How can I debug this connection?
Best regards
Marty
Hi,
in fact the conection from SAP to the destination works using SM59. but the system reply with a connection using RfcOpenEx but this function fails because there is a mixup with the parameters maybe a wrong type.
I will try to debug from the tcode COOPC1 when I start a subscription.
Thanks
Marty
Similar Messages
-
How to debug RFC connection?
I have got an error when SAP execute RfcOpenEx.
How to debug RfcOpenEx and setup breakpoint?
Thanks for your help
MartyHi,
in fact the conection from SAP to the destination works using SM59. but the system reply with a connection using RfcOpenEx but this function fails because there is a mixup with the parameters maybe a wrong type.
I will try to debug from the tcode COOPC1 when I start a subscription.
Thanks
Marty -
hi
could anybody suggest me how to debug RFC
thank you
kalyan.Hello Kalyan,
What do you mean by debug RFC? RFC can be tested using SM59 transaction code.
Regards
Arif Mansuri -
How to Alert RFC connection failure via message mapping? Kindly Help!
Hi Experts,
I have a JMS - XI - RFC scenario.
JMS receives the Rosattenet PIP contents and sends it to RFC function module in remote SAP R/3 system.
I have a requirement where I have to monitor RFC connection failure because of the remote R/3 system being down. I have to send a email alert where the subject contains the PIP number to understand for which PIP the connection failed.
The PIP number exists in the PIP content at the interface.
If I use the Alert configuration in the runtime workbench for monitoring then I cannot dynamically pass the PIP number.
Only way I think of triggering alert is in the message mapping via a Java UDF.
But I am not sure how can I do this? How do I check in the UDF if RFC connection has failed? Is this the correct approach?
How to acheive my requirement? Note that my email subject content is dynamic bacause if PIP number.
Please help!
Thanks
Gopal
Message was edited by:
gopalkrishna baligaHi Gopal,
what version/sps of XI are u running?
The easiest way to do what u want inside a UDF is to
1. use JCo to try estabilish a connection to the remote SAP System
2. if that fails, use JavaMail to send an email message
Let your UDF work on the PIP number, accepting it as input, and (maybe) returning it as output if everything goes ok. Otherwise break the mapping execution as described by Michal in one of his last weblog (using Dynamic Configuration).
Note that the above method doesn't guarantee that the message will be actually delivered, as some seconds could last between your check and the real RFC delivery operated by the Adapter Engine...
I am evaluating a way to do the same with Alert Framework. I will let you know the result!
Cheers,
Alex -
How to close RFC connection in one script coding
In one script, I am using the REF command to call another 2 scripts and these called scripts shd be run on same C36 ( test system). I shd close RFC connection between these 2 scripts.
That is , once the 1s script over the RFC shd be closed and the user has to give usename and pwd then 2nd script shd run.
I have tried with the following code . But it says RFC is not open
REF ( Y04S_FC_RM_CJ88_112 , Y04S_FC_RM_CJ88_1 , C36_999 ). (when execute this script RFC to C36 will be created and after execution that RFC shd be closed so I included following ABAP code)
ABAP.
data : dest type RFCDEST.
move 'S4_SAPC36999' to dest.
move dest to v_dest.
*--Close the connection before opening it incase it is opened
call function 'RFC_CONNECTION_CLOSE'
exporting
destination = dest
exceptions
destination_not_open = 1
others = 2.
if sy-subrc <> 0.
endif.
move sy-subrc to v_subrc.
ENDABAP.
REF ( Y04S_FC_RM_CJ44_112 , Y04S_FC_RM_CJ44_1 , C36_999 ). (here agagin the RFC will be created and this script will be exectued.)In one script, I am using the REF command to call another 2 scripts and these called scripts shd be run on same C36 ( test system). I shd close RFC connection between these 2 scripts.
That is , once the 1s script over the RFC shd be closed and the user has to give usename and pwd then 2nd script shd run.
I have tried with the following code . But it says RFC is not open
REF ( Y04S_FC_RM_CJ88_112 , Y04S_FC_RM_CJ88_1 , C36_999 ). (when execute this script RFC to C36 will be created and after execution that RFC shd be closed so I included following ABAP code)
ABAP.
data : dest type RFCDEST.
move 'S4_SAPC36999' to dest.
move dest to v_dest.
*--Close the connection before opening it incase it is opened
call function 'RFC_CONNECTION_CLOSE'
exporting
destination = dest
exceptions
destination_not_open = 1
others = 2.
if sy-subrc <> 0.
endif.
move sy-subrc to v_subrc.
ENDABAP.
REF ( Y04S_FC_RM_CJ44_112 , Y04S_FC_RM_CJ44_1 , C36_999 ). (here agagin the RFC will be created and this script will be exectued.) -
How to Debug RFC Enabled FM ?
Hello All,
I want to debug an RFC Enabled FM.
I've written a small Test program to check this.
DATA: eenumber LIKE bapip2001-pernr,
subtype LIKE bapip2001-subty,
objectid LIKE bapip2001-objps,
lockindicator LIKE bapip2001-sprps,
validitybegin LIKE bapip2001-begda,
validityend LIKE bapip2001-endda,
recordnumber LIKE bapip2001-seqnr.
CALL FUNCTION 'BAPI_ABSENCE_GETDETAIL
EXPORTING
employeenumber = eenumber
subtype = subtype
objectid = objectid
lockindicator = lockindicator
validitybegin = validitybegin
validityend = validityend
recordnumber = recordnumber
* IMPORTING
* RETURN =
* START =
* END =
* ABSENCETYPE =
* ABSENCEDAYS =
* ABSENCEHOURS =
* NAMEOFABSENCETYPE =
IF sy-subrc <> 0.
WRITE:/ 'UNsuccessful'.
ENDIF.
When a Break Point is kept at the above FM and When I press F5 the cursor is going into the FM .
But when I specify the Destination in the Call Statement as :
CALL FUNCTION 'BAPI_ABSENCE_GETDETAIL' DESTINATION 'SID_010'
EXPORTING
employeenumber = eenumber
subtype = subtype
objectid = objectid
lockindicator = lockindicator
validitybegin = validitybegin
validityend = validityend
recordnumber = recordnumber
* IMPORTING
* RETURN =
* START =
* END =
* ABSENCETYPE =
* ABSENCEDAYS =
* ABSENCEHOURS =
* NAMEOFABSENCETYPE =
The control is not going into the FM.
Can any one tell me how to debug the FM within a different system ?
Regards,
Deepu.KHi Deepu,
Your function module is at other system and you are calling it at some other system.
I hope you know on which system your function module exists.
First debug your coding at your system where you are calling this RFC Function Module and go to that point where your function module starts, now check the export data here
And
go to that system where this function module exists and give the same export data there and debug this Function Module at that system.
Reward points, if helpful,
Sandeep Kaushik -
The RFC connections to the R/3 backend system are not closed when I close my iviews which are created in the Visual Composer. Each time the iview is reloaded, an additional RFC connection is opened...
Has someone a solution for this problem?
Kind regards
FrankHi Frank,
The connector pool keep the connection alive to be reused by the model iViews datasource, those connections will be closed at the timeout or when CLEANUP runs.
It's not a problem is the way how the connector framework works
You can adapt the timeout according SAP Notes 913483 & 314530
Best Regards, Luis -
How to get DB Connection using IConnectorService
Hi All
I need some documents or help on how to make a jdbc connection using IConnectorService framework. Can anybody help?
Warm Regards
ShubhadipHi Shubhadip,
I have some usefull code for you.
//This method is to perform the connection to the DataBase, where
// the Database name is myDatabase
public IConnection getConnect()
IConnection myconnection = null;
IPortalComponentRequest request = (IPortalComponentRequest) this.getRequest();
Object connectorservic = PortalRuntime.getRuntimeResources().getService(IConnectorService.KEY);
IConnectorGatewayService cgService = (IConnectorGatewayService)connectorservic;
mylogger = request.getLogger();
ConnectionProperties cp = new ConnectionProperties(request.getLocale(), request.getUser());
try {
myconnection = cgService.getConnection("myDatabase", cp);
catch (Exception e)
mylogger.severe(e.getMessage());
return myconnection;
Kind Regards,
Al-Suwaiyel -
How to share internet connection using socketserver?
Hello guys is this possible? i want to share my internet connection programmaticaly using java for example i have a one computer that has internet connection and i want to run socketserver from the computer that has internet connection and share the internet connection to another computer that has no internet connection using socket how to do that in java?
jhovarie wrote:
Hello guys is this possible? i want to share my internet connection programmaticaly using java for example i have a one computer that has internet connection and i want to run socketserver from the computer that has internet connection and share the internet connection to another computer that has no internet connection using socket how to do that in java?No, this is mostly a admin (networking ) issue. if you want to do so, you require a router (switch), one end should be connected to internet connection, and then connect the rest of the computers to router. you will be able to access the internet. -
SOAMANAGER: RFC connection uses 'anonymous' PSE?
Hi Everybody - We want to configure our ERP 6.04 system to consume an external web service. The web service will be accessed by an ABAP program (not by the end user). We want to use SSL and a service userid/password.
If the developer uses the supplied WSDL and tcodes SE80 and soamanager, the automatic configuration generates an RFC connection that does not contain userid and password and uses the SSL Client Standard PSE (SAPSSLC.pse). If the developer uses a manual configuration in soamanager in order to specify basic authentication in addition to SSL then the RFC connection will contain the userid/password, but it will also specify the 'anonymous' PSE (SAPSSLA.pse).
1. Does the above sound correct?
2. Are there any real issues with using the 'anonymous' PSE instead of the standard client PSE?
3. Will the 'anonymous' PSE present a problem when we go to QA and production (which will use CA signed certificates)?
4. Is there a way to specify SSL with userid/password and get the RFC connection to use the standard client PSE?
Thanks for your help - points awarded for helpful input.
JeffHi Jeff,
Yes, you are right automatic LP generation can't change via change in RFC destination but manual LP can be changed via RFC destination.
See SAP help:http://help.sap.com/saphelp_nw70/helpdata/en/5b/2e423c0bcc4a7ee10000000a114084/content.htm and read point 3 and 4 carefully.
STANDARD = "Mutual Authentication"
Anonymous = "Only server Authentication"
Make sure you configured/activated correct security setting as per following document:
Configure ABAP AS: http://help.sap.com/saphelp_nw70/helpdata/en/65/6a563cef658a06e10000000a11405a/content.htm
Workaround I'll suggest that create another LP manually with exact settings you can see in automatic created LP and then change generated RFC destination (you can change manually generated LP's RFC destination).
To use standard client SSL you need to configure mutual trust between consumer and provider (I haven't configured it myself).
I'll investigate more and come back to you.
Regards,
Gourav -
I am trying to create a JDeveloper/Data Connection using com.oracle.ias.jdbc.db2.DB2Driver. The driver is registered from a User Libraries: DataDirect JDBC. I have the following class path for the library:
E:\DataDirect\3.4\lib\YMdb2.jar;E:\DataDirect\3.4\lib\YMbase.jar;E:\DataDirect\3.4\lib\YMutil.jar
I have no trouble configuring the connection but when I test it and I got No suitable driver Vendor code 0. Whats wrong? I have successfully created several database connections using Oracle thin driver. This is first time I am using a third party driver. Has any one successfully create a database connection using the com.oracle.ias.jdbc.db2.DB2Driver?Hi
Since the error points to the unavailability of the driver class,can you double check your library claspath entries again.
I just tried a DB2 connection using the following properties and the connection went through fine:
Driver class name: com.oracle.ias.jdbc.db2.DB2Driver
URL: jdbc:merant:db2://<host_name>:50000;DatabaseName=SAMPLE
Thanks
Prasanth -
How to setup RFC Connection for SAPOSS?
Dear Experts,
I tried to setup the RFC connection for SAPOSS based on the following settings, but when I test connection, it failed.
Target system : OSS
Msg. Server : ... ( this where I stuck which I'm not sure what to fill in)
Group : EWA
Client : 001
User : OSS_RFC
Password : CPIC
Does anyone know the right settings?
Regards,
AbrahamHi all,
Do I really need to setup our own SAProuter if our firewall doesn't block any outbound IP address?
I've tried the following settings in OSS1 but still failed to connect.
SAProuter at SAP :-
Name : sapserv3 ( or sapserv7 or sapserv2)
IP address : 147.204.2.5 (or 194.39.134.35 or 194.39.131.34)
Instance no : 99
SAPNet Message Server
Name : oss001
DB Name : 001
Instance No : 01
I left the SAProuter1 and SAProuter2 (at customer site) blank.
Did I miss out anything? -
How to solved RFC connection (EarlyWatch)
Hi,
I having problem in Solution Manager 4.0 (EarlyWatch Report)
R/3 landscape (NDV,NQA,NPR)
NDV and NPR does works fine and getting EWA everyweek which is schedule every week
NQA does not work at all
Screenshot here:
http://www.flickr.com/photos/25222280@N03/2586790185/sizes/o/
1. I check RFC connection in solution manager (sdccn)
Selected NQA, and click RFC button
Login NQA tr: sdccn --> taskLog --> from menu GOTO --> setting --> Processor task
Checkhosts then double click (RFC destination) I got error: "no host fulfils the requirements of service data control center"
Is there any problem please let me know
Screenshot here:
http://www.flickr.com/photos/25222280@N03/2586794197/sizes/o/
2. Goto SM59 --> under R/3 connection --> check connection "SM_NSMCLIENT100_BACK" does works fine...
screenshot here:
http://www.flickr.com/photos/25222280@N03/2586794219/sizes/o/
Question: please let me know where and what i am missing or wrong ?
Thanks in AdvancedHi Issue,
These can solved in two ways.
1. You dont need an trusted RFC for EWA. You can get the reports w/o TRUSTED. if you really need this, then follow option 2.
2. Add S_RFC & S_RFCACL autorization objects to your ID in both systems. Solman & Target system.
This will solve your issue.
Thanks, -
How to find rfc connection exist between R/3 and APO ?
Hi all,
i wanted to find out...
rfc connection exist between R/3 and APO ?
kindly help in this regard..
Thanks
JoshiHi Sridhar,
If u have access to SM59 transaction then u can check and test the connection there it self.
If u don't have access then check the table RFCDES where all RFC destinatios defined for your system is stored.
Thanks,
Vinod. -
How is the db connection used... and how to use the queries
dear sir,
i have to important question.
i am pasting the code of a jsp file below.... please look in to this...
in this page.. how is he making a database connection... and in this page
where are the select statements and queries.... i have tried many times reading
this ..but i could not find the queries ..not even any one.
if anyone sees this jsp file also ... he will not be able to see the queries.
can u please help me .. how to do this type of connection and also how to use queries
like select insert and delete and update .
an example will help me out...please help me...
Ramesh
the file is below....
<%@ include file="jtfincl.jsp" %>
<%@ page language="java" %>
<%@ page import="oracle.apps.ibu.common.IBUContext" %>
<%@ page import="oracle.apps.ibu.common.IbuException" %>
<%@ page import="oracle.apps.ibu.common.Employee" %>
<%@ page import="oracle.apps.ibu.common.EmployeeInfo" %>
<%@ page import="oracle.jdbc.driver.*" %>
<%@ page import="oracle.apps.jtf.aom.transaction.*" %>
<%@ page import="oracle.apps.jtf.base.resources.*" %>
<%@ page import="oracle.apps.jtf.base.interfaces.MessageManagerInter"%>
<%@ page import="oracle.apps.ibu.registration.IbuRegistration" %>
<%@ page import="oracle.apps.ibu.registration.CustomerVO" %>
<%@ page import="oracle.apps.ibu.common.IDNamePair" %>
<%@ page import="oracle.apps.ibu.common.*" %>
<%@ page import="oracle.apps.ibu.registration.*" %>
<%@ page import="java.math.BigDecimal" %>
<jsp:useBean id = "_displayManager"
class = "oracle.apps.ibu.common.DisplayManager"
scope = "application" />
<jsp:useBean id = "ibuPromptManager"
class = "oracle.apps.ibu.common.PromptManager"
scope = "application" />
<%
String appName= "IBU";
boolean stateless=true; // used for jtfsrfp.jsp
SiteProperty.load();
String username = SiteProperty.getGuestUsername();
String password = SiteProperty.getGuestPassword();
%>
<%@ include file="jtfsrfp.jsp" %>
<%
String forwardURL = null;
String backURL = null;
String emailAddress = null;
long employeeID = -1;
String submitType = (String) request.getParameter("submitType");
IBUContext context = new IBUContext(fwSession);
String errorKey = "";
String errorMessage = "";
String errorStack = "";
boolean currentStatus = true;
Object lockx = new Object ();
OracleConnection conn = null;
try
TransactionScope.begin(lockx);
try
conn = (OracleConnection)
TransactionScope.getConnection();
catch ( Exception e )
throw new FrameworkException("Error getting connection..");
if ( conn == null )
throw new FrameworkException("Error getting connection..");
String[] textMsgs = new String[3];
MessageManagerInter msgMgr = Architecture.getMessageManagerInstance();
textMsgs[0] = msgMgr.getMessage("IBU_RG_CONTRACT24");
//textMsgs[0] = " is not a valid employee email address.";
textMsgs[1] = msgMgr.getMessage("IBU_RG_CONTRACT25");
//textMsgs[1] = " Cannot get the employee id.";
textMsgs[2] = msgMgr.getMessage("IBU_RG_CONTRACT13");
//textMsgs[2] = "submitType is null, please check program.";
if ( (submitType != null) && "LOGIN".equals( submitType ) )
forwardURL="jtflogin.jsp";
backURL="jtflogin.jsp";
else if ( (submitType != null) && "EMPLOYEE_CHECK".equals( submitType ) )
forwardURL="ibuemplcheck.jsp";
backURL="ibuemplcheck.jsp";
else if ( (submitType != null) && "EMPLOYEE_NUMBER_SUBMIT".equals( submitType ) )
backURL="ibuemplcheck.jsp";
emailAddress = (String) request.getParameter("emailAddress");
pageContext.setAttribute("emailAddress", emailAddress , PageContext.REQUEST_SCOPE);
employeeID = IbuRegistration.getEmployeeID(conn,emailAddress);
if (employeeID == -1)
throw new IbuRegException(emailAddress + " "+textMsgs[0] + " " +textMsgs[1]);
//validate employee
currentStatus = Employee.isValidate(conn,emailAddress);
//currentStatus = IbuRegistration.isEmployeeValid(conn,emailAddress);
if (!currentStatus)
throw new IbuRegException(emailAddress + " " + textMsgs[0]);
EmployeeInfo employee = Employee.findEmployee(conn,employeeID);
pageContext.setAttribute("employee", employee , PageContext.REQUEST_SCOPE);
pageContext.setAttribute("employeeIDStr", Long.toString(employeeID) , PageContext.REQUEST_SCOPE);
forwardURL="ibuemplinput.jsp";
else
{ // Cancel button was pressed
throw new IbuRegException(textMsgs[2]);
/* "ibuccsii.jsp"; */
catch ( IbuException e )
TransactionScope.setRollbackOnly();
errorMessage = e.getMessage();
errorStack = IbuRegException.getStack(e);
pageContext.setAttribute("errorMessage", errorMessage , PageContext.REQUEST_SCOPE);
pageContext.setAttribute("errorStack", errorStack , PageContext.REQUEST_SCOPE);
forwardURL = backURL;
catch (IbuRegException e)
TransactionScope.setRollbackOnly();
errorMessage = e.getMessage();
errorStack = e.getStack();
pageContext.setAttribute("errorMessage", errorMessage , PageContext.REQUEST_SCOPE);
pageContext.setAttribute("errorStack", errorStack , PageContext.REQUEST_SCOPE);
forwardURL = backURL;
catch ( Exception e )
TransactionScope.setRollbackOnly();
errorMessage = e.getMessage();
errorStack = IbuRegException.getStack(e);
pageContext.setAttribute("errorMessage", errorMessage , PageContext.REQUEST_SCOPE);
pageContext.setAttribute("errorStack", errorStack , PageContext.REQUEST_SCOPE);
forwardURL = backURL;
//throw new FrameworkException( e , "IBU_UNEXPECTED_EXCEPTION");
finally
TransactionScope.releaseConnection( conn );
TransactionScope.end ( lockx );
if (forwardURL == null)
forwardURL="jtflogin.jsp";
%>
<jsp:forward page= "<%= forwardURL %>" />
<%@ include file="jtferlp.jsp" %>dear sir,
i have to important question.
i am pasting the code of a jsp file below.... please look in to this...Note that this is an OCI forum. Since your code is using Oracle's JDBC driver to connect, I would suggest posting in the JDBC forum for more information.
in this page.. how is he making a database connection...
try
conn = (OracleConnection)
TransactionScope.getConnection();
catch ( Exception e )
throw new FrameworkException("Error getting connection..");
and in this page
where are the select statements and queries.... There may be queries in the Employee objects or in the include files.
Justin
Maybe you are looking for
-
Tax Amount for Invoice Creation using BAPI_INCOMNGINVOICE_CREATE ?
Hi, I am using BAPI_INCOMNGINVOICE_CREATE function module for cearting Invoice for a PO with referrence to Goods Receipt. In this case got a problem that if i did GRC for 10 Quantity for a Line Item in PO which consists 20 Quantity then i need t
-
How can I make an image tile length of browser without using it as background image?
I understand that if you use the rectangle tool and stretch it to the edge of the page, triggerring the red margin, the tiled image is supposed to stretch the length of the browser. Although this works for width, tiling horizontally, for some reason,
-
Using a studio display with MacBook Pro
I have a MacBook Pro and an older 17" Studio Display with a DVI-D male connector. What do I need to drive the studio display from my MBP? And where do I get them?
-
Production Order: warning when Basic finish date is before scheduled finish
Hello experts, We will set in config OPU3 (scheduling parameters for prod order) Adjust dates = 2 Do not adjust basic dates, ... Essentially this will allow the shop floor controller to change scheduled date ie. production dates without affecting bas
-
Download links for beta releases and release notes
All Where is the download links for all the beta-release packages and their release notes?