VB6 - Keep Connection open?

Hi,
I have developed a VB6 application which logs on / connects to SAP and executes a number of RFC's.
At the moment I have left the connection open throughout the running of my application, so that several RFC's can be executed without the need to log on / off each time. However, I have discovered that SAP messages being returned to me do not appear to be cleared (from memory) giving me incorrect messages. If the user stops and starts the connection each time before executing an RFC , this does not happen and messages / results are as expected.
Should I be killing the connection for every RFC I execute, or am I missing some more basic refresh type of command?
Another question, which may well be answered by the previous one: one of the RFC's I need to execute involves uploading from one line of data to many lines of data. I intend to loop through each line and execute the RFC for each line of data, as this appears to be how the RFC handles it. Given that I may have many lines and therfore many RFC calls, is it best to repeatedly call the RFC without closing the connection, as posted above? If I have to close the connection and re-open it each time as well as call the RFC, it could turn out to be a lengthy process.
Hope you can advise,
thanks,
Steve

Hi,
I'm not quite sure I understand your question. If you want to open only a single connection and use only that connection, you'll have to do that in your code.
What is your DBA complaining about exactly though? Do you accumulate sessions, is that why he/she is concerned? You have idle sessions not being used? How many sessions? etc.
I'd check to make sure your code is cleaning up properly, and use connection pooling if you're not already.
Hope it helps,
greg

Similar Messages

  • SQL Developer 1.5.4: "Keep alive" setting to keep connections open?

    Is there any way to configure SQL Developer 1.5.4 such that it "pings" the server every now then to keep the connection open?
    It's very frustrating to be working on a script, step away from it for a while, and have SQL Developer freeze when trying to execute the next SQL statement.
    What can I do?
    My workaround--execute a "dummy" SQL statement like "select * from dual;" every now and then to keep a connection open.
    Thanks.
    Dana

    I have had this problem till I had a RAM upgrade.
    Since I have had the upgrade JDeveloper also responds well.
    A way to check is via task manager, if PF usage is more than you physical RAM size it is a indicator that you need more RAM or shut down some application that is hogging memory.
    Just to rule out if its not some other problem, have you tried working in SQL Developer running by itself or with one other program.
    Regards
    Edited by: io-into oracle on Jun 24, 2009 11:39 AM

  • Why does JDBC keep connections open even though I close the resultsets?

    I attached my program and my output. Please bear with me for the long output. My question here is why do the connections remain even though I closed the resultsets. I need to reuse my prepared statements, but don't want to keep the oracle sessions open. Is this possible? What do I need to do?
    If you notice in the program, I have executed the query to find the number of open sessions 5 times.
    1) After creating the connections
    2) After creating the prepared statements
    3) After executing them
    4) After getString on the resultSets
    5) After closing the resultsets.
    And the sessions are still there even is Step 5 :-(
    import java.sql.*;
    * Title:
    * Description:
    * Copyright: Copyright (c) 2001
    * Company:
    * @author
    * @version 1.0
    public class Test {
    String dburl = "jdbc:oracle:thin:@oracle92:1521:oracle92";
    String query = "select s.username,s.sid ,s.logon_time, s.serial#,sql.sql_text"+
    " from v$session s, v$sqltext sql where sql.address = "+
    "s.sql_address and sql.hash_value = s.sql_hash_value "+
    "and upper(s.username) like 'KRTEMP%'"+
    " order by s.username ,s.sid ,s.serial# ,sql.piece" ;
    // String query = "select s.username, s.sid ,s.logon_time, s.status from v$session s where upper(s.username) like 'KRTEMP%'";
    public Test(int num) throws Exception {
    Class.forName("oracle.jdbc.driver.OracleDriver");
    Connection[] con = new Connection[num];
    for(int i=0; i<num; i++) {
    con[i] = DriverManager.getConnection(dburl, "krtemp", "krtemp");
    executeQuery();
    PreparedStatement[] ps = new PreparedStatement[num];
    for(int i=0; i<num; i++) {
    ps[i] = con.prepareStatement("select * from contact");
    executeQuery();
    ResultSet[] rs = new ResultSet[num];
    for(int i=0; i<num; i++) {
    rs[i] = ps[i].executeQuery();
    executeQuery();
    for(int i=0; i<num; i++) {
    ResultSetMetaData meta = rs[i].getMetaData();
    while(rs[i].next()) {
    for(int j=1; j<=meta.getColumnCount(); j++) {
    rs[i].getString(j);
    executeQuery();
    for(int i=0; i<num; i++) {
    rs[i].close();
    executeQuery();
    private void executeQuery() throws Exception {
    Connection con = DriverManager.getConnection(dburl, "krtemp", "krtemp");
    PreparedStatement ps = con.prepareStatement(query);
    ResultSet rs = ps.executeQuery();
    ResultSetMetaData meta = rs.getMetaData();
    System.out.println("-----");
    while(rs.next()) {
    for(int i=1; i<=meta.getColumnCount(); i++) {
    System.out.print(rs.getString(i));
    System.out.print(" ");
    System.out.println();
    System.out.println("-----");
    public static void main(String[] args) throws Exception {
    Test test = new Test(5);
    The output is
    KRTEMP 9 2005-06-27 17:09:30.0 5436 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS WH
    ERE PARAMETER ='NLS_
    KRTEMP 9 2005-06-27 17:09:30.0 5436 DATE_FORMAT'
    KRTEMP 34 2005-06-26 18:51:01.0 3629 rename tstore to store
    KRTEMP 37 2005-06-27 17:09:25.0 4209 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 37 2005-06-27 17:09:25.0 4209 DATE_FORMAT'
    KRTEMP 74 2005-06-27 17:09:26.0 17625 select appId from profile_application_tabl
    e wher
    KRTEMP 74 2005-06-27 17:09:26.0 17625 e appName=:1 and appVersion=:2
    KRTEMP 83 2005-06-27 17:09:25.0 1771 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 83 2005-06-27 17:09:25.0 1771 DATE_FORMAT'
    KRTEMP 105 2005-06-27 17:09:30.0 3296 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 105 2005-06-27 17:09:30.0 3296 DATE_FORMAT'
    KRTEMP 111 2005-06-27 17:09:25.0 4878 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 111 2005-06-27 17:09:25.0 4878 DATE_FORMAT'
    KRTEMP 153 2005-06-27 17:09:30.0 31065 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 153 2005-06-27 17:09:30.0 31065 DATE_FORMAT'
    KRTEMP 163 2005-06-27 17:09:30.0 3205 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 163 2005-06-27 17:09:30.0 3205 DATE_FORMAT'
    KRTEMP 183 2005-06-27 17:09:30.0 3465 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 183 2005-06-27 17:09:30.0 3465 DATE_FORMAT'
    KRTEMP 191 2005-06-27 17:09:26.0 5438 select appId from profile_application_tabl
    e wher
    KRTEMP 191 2005-06-27 17:09:26.0 5438 e appName=:1 and appVersion=:2
    KRTEMP 256 2005-06-27 17:09:30.0 2718 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 256 2005-06-27 17:09:30.0 2718 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 256 2005-06-27 17:09:30.0 2718 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 256 2005-06-27 17:09:30.0 2718 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 9 2005-06-27 17:09:30.0 5436 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS WH
    ERE PARAMETER ='NLS_
    KRTEMP 9 2005-06-27 17:09:30.0 5436 DATE_FORMAT'
    KRTEMP 34 2005-06-26 18:51:01.0 3629 rename tstore to store
    KRTEMP 37 2005-06-27 17:09:25.0 4209 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 37 2005-06-27 17:09:25.0 4209 DATE_FORMAT'
    KRTEMP 74 2005-06-27 17:09:26.0 17625 select appId from profile_application_tabl
    e wher
    KRTEMP 74 2005-06-27 17:09:26.0 17625 e appName=:1 and appVersion=:2
    KRTEMP 83 2005-06-27 17:09:25.0 1771 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 83 2005-06-27 17:09:25.0 1771 DATE_FORMAT'
    KRTEMP 105 2005-06-27 17:09:30.0 3296 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 105 2005-06-27 17:09:30.0 3296 DATE_FORMAT'
    KRTEMP 111 2005-06-27 17:09:25.0 4878 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 111 2005-06-27 17:09:25.0 4878 DATE_FORMAT'
    KRTEMP 153 2005-06-27 17:09:30.0 31065 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 153 2005-06-27 17:09:30.0 31065 DATE_FORMAT'
    KRTEMP 163 2005-06-27 17:09:30.0 3205 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 163 2005-06-27 17:09:30.0 3205 DATE_FORMAT'
    KRTEMP 183 2005-06-27 17:09:30.0 3465 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 183 2005-06-27 17:09:30.0 3465 DATE_FORMAT'
    KRTEMP 191 2005-06-27 17:09:26.0 5438 select appId from profile_application_tabl
    e wher
    KRTEMP 191 2005-06-27 17:09:26.0 5438 e appName=:1 and appVersion=:2
    KRTEMP 232 2005-06-27 17:09:31.0 5893 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 232 2005-06-27 17:09:31.0 5893 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 232 2005-06-27 17:09:31.0 5893 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 232 2005-06-27 17:09:31.0 5893 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 34 2005-06-26 18:51:01.0 3629 rename tstore to store
    KRTEMP 37 2005-06-27 17:09:25.0 4209 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 37 2005-06-27 17:09:25.0 4209 DATE_FORMAT'
    KRTEMP 74 2005-06-27 17:09:26.0 17625 select appId from profile_application_tabl
    e wher
    KRTEMP 74 2005-06-27 17:09:26.0 17625 e appName=:1 and appVersion=:2
    KRTEMP 83 2005-06-27 17:09:25.0 1771 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 83 2005-06-27 17:09:25.0 1771 DATE_FORMAT'
    KRTEMP 111 2005-06-27 17:09:25.0 4878 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 111 2005-06-27 17:09:25.0 4878 DATE_FORMAT'
    KRTEMP 232 2005-06-27 17:09:31.0 5893 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 232 2005-06-27 17:09:31.0 5893 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 232 2005-06-27 17:09:31.0 5893 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 232 2005-06-27 17:09:31.0 5893 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 256 2005-06-27 17:09:31.0 2783 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 256 2005-06-27 17:09:31.0 2783 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 256 2005-06-27 17:09:31.0 2783 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 256 2005-06-27 17:09:31.0 2783 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 9 2005-06-27 17:09:30.0 5436 select * from contact
    KRTEMP 34 2005-06-26 18:51:01.0 3629 rename tstore to store
    KRTEMP 37 2005-06-27 17:09:25.0 4209 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 37 2005-06-27 17:09:25.0 4209 DATE_FORMAT'
    KRTEMP 74 2005-06-27 17:09:26.0 17625 select appId from profile_application_tabl
    e wher
    KRTEMP 74 2005-06-27 17:09:26.0 17625 e appName=:1 and appVersion=:2
    KRTEMP 83 2005-06-27 17:09:25.0 1771 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 83 2005-06-27 17:09:25.0 1771 DATE_FORMAT'
    KRTEMP 105 2005-06-27 17:09:30.0 3296 select * from contact
    KRTEMP 111 2005-06-27 17:09:25.0 4878 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 111 2005-06-27 17:09:25.0 4878 DATE_FORMAT'
    KRTEMP 153 2005-06-27 17:09:30.0 31065 select * from contact
    KRTEMP 163 2005-06-27 17:09:30.0 3205 select * from contact
    KRTEMP 173 2005-06-27 17:09:31.0 3922 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 173 2005-06-27 17:09:31.0 3922 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 173 2005-06-27 17:09:31.0 3922 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 173 2005-06-27 17:09:31.0 3922 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 183 2005-06-27 17:09:30.0 3465 select * from contact
    KRTEMP 191 2005-06-27 17:09:26.0 5438 select appId from profile_application_tabl
    e wher
    KRTEMP 191 2005-06-27 17:09:26.0 5438 e appName=:1 and appVersion=:2
    KRTEMP 232 2005-06-27 17:09:31.0 5893 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 232 2005-06-27 17:09:31.0 5893 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 232 2005-06-27 17:09:31.0 5893 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 232 2005-06-27 17:09:31.0 5893 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 256 2005-06-27 17:09:31.0 2783 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 256 2005-06-27 17:09:31.0 2783 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 256 2005-06-27 17:09:31.0 2783 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 256 2005-06-27 17:09:31.0 2783 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 9 2005-06-27 17:09:30.0 5436 select * from contact
    KRTEMP 34 2005-06-26 18:51:01.0 3629 rename tstore to store
    KRTEMP 37 2005-06-27 17:09:25.0 4209 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 37 2005-06-27 17:09:25.0 4209 DATE_FORMAT'
    KRTEMP 74 2005-06-27 17:09:26.0 17625 select appId from profile_application_tabl
    e wher
    KRTEMP 74 2005-06-27 17:09:26.0 17625 e appName=:1 and appVersion=:2
    KRTEMP 83 2005-06-27 17:09:25.0 1771 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS W
    HERE PARAMETER ='NLS_
    KRTEMP 83 2005-06-27 17:09:25.0 1771 DATE_FORMAT'
    KRTEMP 105 2005-06-27 17:09:30.0 3296 select * from contact
    KRTEMP 111 2005-06-27 17:09:25.0 4878 SELECT VALUE FROM NLS_INSTANCE_PARAMETERS
    WHERE PARAMETER ='NLS_
    KRTEMP 111 2005-06-27 17:09:25.0 4878 DATE_FORMAT'
    KRTEMP 153 2005-06-27 17:09:30.0 31065 select * from contact
    KRTEMP 163 2005-06-27 17:09:30.0 3205 select * from contact
    KRTEMP 183 2005-06-27 17:09:30.0 3465 select * from contact
    KRTEMP 191 2005-06-27 17:09:26.0 5438 select appId from profile_application_tabl
    e wher
    KRTEMP 191 2005-06-27 17:09:26.0 5438 e appName=:1 and appVersion=:2
    KRTEMP 204 2005-06-27 17:09:32.0 1478 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 204 2005-06-27 17:09:32.0 1478 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 204 2005-06-27 17:09:32.0 1478 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 204 2005-06-27 17:09:32.0 1478 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 232 2005-06-27 17:09:31.0 5893 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 232 2005-06-27 17:09:31.0 5893 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 232 2005-06-27 17:09:31.0 5893 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 232 2005-06-27 17:09:31.0 5893 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece
    KRTEMP 256 2005-06-27 17:09:31.0 2783 select s.username,s.sid ,s.logon_time, s.s
    erial#,sql.sql_text fr
    KRTEMP 256 2005-06-27 17:09:31.0 2783 om v$session s, v$sqltext sql where sql.ad
    dress = s.sql_address
    KRTEMP 256 2005-06-27 17:09:31.0 2783 and sql.hash_value = s.sql_hash_value and
    upper(s.username) like
    KRTEMP 256 2005-06-27 17:09:31.0 2783 'KRTEMP%' order by s.username ,s.sid ,s.s
    erial# ,sql.piece

    Why do the connections stay open? Because you haven't closed them.
    You answered your own question: obviously closing the ResultSet is NOT the same thing as closing the connection.
    When you do a query, you want to get the connection, statement, and result set, load the data from the result set into an object or data structure, and then immediately close them all again in reverse order of creation. You want to keep the scope as narrow as possible. You want to use a connection pool to keep the cost of obtaining a connection down. You should leave caching of the PreparedStatements to the JDBC driver.
    %

  • Workstations keeping connection open to the ZfD server

    Hi,
    I have the following situation:
    NetWare 5.1 SP6 server, with ZENworks for Desktops 3.2 SP3 installed. We
    use ZEN Imaging. Now, a lot of our workstations are keeping a conenction
    open to the server. In Monitor, the Network Address shows the IP address
    of our server. This makes it very hard for our administrators to keep
    track on which PC is connected to the network at the moment.
    How can I clear these connections, or better yet: how can I prevent them
    from coming up ?
    Thanks in advance.
    Arjan

    Arfman,
    It appears that in the past few days you have not received a response to your posting. That concerns us, and has triggered this automated reply.
    Has your problem been resolved? If not, you might try one of the following options:
    - Do a search of our knowledgebase at http://support.novell.com/search/kb_index.jsp
    - Check all of the other support tools and options available at http://support.novell.com in both the "free product support" and "paid product support" drop down boxes.
    - You could also try posting your message again. Make sure it is posted in the correct newsgroup. (http://support.novell.com/forums)
    If this is a reply to a duplicate posting, please ignore and accept our apologies and rest assured we will issue a stern reprimand to our posting bot.
    Good luck!
    Your Novell Product Support Forums Team
    http://support.novell.com/forums/

  • Keeping Connection open...

    If I have a thread that keeps a Conneciton open (or atleast monitors it and re-opens it if it closes for some reason) is this a good way to do it?
    public void run(){
         //-----Loop indefinetly
         while(!interrupted()){
              //-----Connect to the database
              try{                    
                  Class.forName("com.mysql.jdbc.Driver").newInstance();
                  //Where ams is the parent object that has the Connection as one of it's properties
                        ams.setConnection(DriverManager.getConnection(ams.getMySqlConnectionString()));
                  while(!ams.getConnection().isClosed()){sleep(1000);}
              //-----Display exception and sleep for a bit
              }catch(Exception e){try {sleep(1000);}catch (Exception ex){}}
    }

    I only need one connection so pooling seems to be an over the top way of keepign it open.
    I just wanted to put a simple little thread around my Connection object checking if it is open every so often and if not reopening it... Do you still think pooling is the way to go?

  • Keep connection opened for loop

    Hello Community!
    I'm using JCO to connect a Flex application to a backend SAP System.
    This is how I connect to the system:
        - Edit configuration file for SAP System
        - JCoDestination dest = JCoDestinationManager.getDestination(configurationFile)
        - JCoFunction func = dest.getRepository.getFunction('myFunction')
        - func.execute(dest)
    I think that the connection is established when I execute the JCoFunction and then closes inmediatly after the execution is done.
    The issue I'm having is that I have a RFC FM in SAP that is really fast (at least in SAP). I'm calling this FM via the JCo in a Loop and it's taking forever.
    I think that the long response time comes from the connection... But don't know how to resolve it but creating a FM that call myfunction in a Loop and the returns it to Java...
    Thanks for any help you can provide.
    Regards,
    BS_C3

    By default JCo 3 uses connection pools. You can check the connection parameters in interface DestinationDataProvider. Here you can especially check out parameters jco.destination.expiration_time and jco.destination.expiration_check_period.
    So connections are reused (not closed) as long as you don't create new destination objects with each call. Note that usually there's quite some overhead with the first invocation of an RFC call if you have to retrieve the metadata from a SAP repository. I.e. if you trace the calls you'll see that initially there's quite a few calls to figure out the function module interface of the called RFC and all corresponding parameters (e.g. if structures or tables are used those have to be retrieved as well). So you can gain some performance by adding the metadata of the used functions to the repository (or usage of a JCoCustomRepository and loading for example saved metadata before executing the RFC calls).
    To check performance I'd enable tracing and possibly look at some of the other options for measuring performance (e.g. check out JCoDestination.setThroughput() and other options).
    Cheers, harald

  • Keeping the connection open while in sleep

    I was just wondering if there is anyway to keep the internet connection open while the computer is in sleep mode? I have looked around for a little bit but I figured someone else probably already has an answer.
    Just to clarify I don't mean closing the laptop but just putting it into sleep mode. I've read you can't keep a connection open while the laptop is closed but I was wondering if there was a difference between putting it to sleep and closing the laptop.
    Message was edited by: Boogie Chillen

    No difference. If you need to keep the connection open, which is what I do, then set the Energy Saver to never sleep.

  • Keep DB Connection Open

    I have an Oracle stored procedure that I need to call for a list of records in Crystal.
    What I have done is created a UFL to make the call and provide the return results.
    I call the Custom Function for each record returned however, it's taking a long time to process.
    I believe this is because the connection to the oracle database is being opened, called and closed for each record.
    Is there any way to open the connection when the reports starts running, return the results for each record and then close the connection when the report completes?
    Any help would be appreciated.
    FYI - I am using CRXI R2
    Ray

    Hi Raymond,
    The reason why CR opens/closes for each record is because you are using a UFL it's going to be processed on the second pass of the report which means because it's a formula CR will process it after the connection is closed. If CR can convert the formula into SQL then it happens server side but in your case you need to run the query for each record.
    Have you had a look at using a Command Object? It would require returning all of the data but at least the ufl function would then filter on the Command data and not hit the database. You may have to re-write your UFL functions so it doesn't go to the DB but uses the cached data in the Command object.
    Another option would be to write your own OLE DB Provider. DataDirect who we partner with for data sources, offers an SDK so you can build in security and anything else you need or would like to have.
    http://web.datadirect.com/products/custom-driver-sdk/index.html
    As for stopping CR from disconnecting that won't happen. We release the connection to free resources once we are done, keeping the connection open causes problems for all applications like Brian indicated.
    You may have to re-design your report and do the filtering client side rather than server side.
    Thank you
    Don

  • Is there a fix for Mail keeping 4 connections open for one.......?!

    Is there a fix for Mail keeping 4 connections open for one email account setup as IMAP.......?!
    Im just wondering whether this is possible because it means our company website falls over when the processes go over 25! There are a lot of emails.....
    It is a massive pain and ideally we dont want to upgrade our hosting package if we can help it!
    There must be a way round it?! Someone brainy know any tricks?!

    Ernie Stamper wrote:
    Never have encountered this -- more info, please? What are 4 connections, exactly?
    Very simple: Mail opens one connection for each IMAP mailbox on the account. Typically, this means Inbox, Sent Mail, Drafts, and Trash, but also includes Apple Mail To Do and Junk and any mailboxes/folders the user has created.
    The problem is that Mail is keeping these connections open when it's done checking for new mail, even when *Use IDLE command if server supports it* is not enabled. With 4 email accounts on one server, this causes a "500 Internal Server Error" because there are too many processes running. As soon as I quit Mail, my web server resumes serving pages.
    Message was edited by: Don Morris

  • Is it wise to keep the socket connection open?

    When u have a bunch of HTTP requests coming in to a listener server socket, would it be safe to keep my JAVA socket connection open with KeepAlive or simply open/close at will? I thought of a connection of sockets as well. Thoughts? thx!

    It depends which socket your talking about
    The serversocket you want to always be open and listened to
    the sockets it spawns you should close when you've finished the transaction

  • OSB using socket Transport ,how to keep a TCP connection open

    hi my firends,
    i met a problem , our project need build an OSB to control a socket service which is able to transfer a big data file (maybe a voice file,*.wav),and the client program will play the voice file on live.
    So my solution is that : keep a socket (tcp) connection open,client listen port and makes date play.
    but i can't make the OSB socket transport alway open,it will timeout after a few second if have none date received.
    how could i deal with it ... pls let me konw if you have any idea...i will wait you on line
    thanks guys

    Hi,
    I'm not sure if that's achievable using OSB, and even if it was, I don't think OSB was designed having this type of application in mind...
    I understand that you need a media streaming solution and I'm pretty sure that there are plenty of tools out there that can help you in doing that, and maybe some of them can be integrated with OSB in some way...
    Cheers,
    Vlad

  • Ok I am having issues with my HP Enby 100 D410. Need help setting up eprint, and keeping connected.

    I opened up my printer, set it up, connected.  But I cant seem to keep connected.  I have an eprint email address set up, but the printer reset and now wants me to set up an new eprint using a different code.  How do I get the [email protected] email back.  It says "someone already has address..."  duh, that's me..!  This printer has been more than frustrating.  HP support says open 7 days a week, 24 hours a day.  But when I call, they are closed and only open during certain days and hours... why advertise differently?  I also cannot seem to get my printer to align the printer cart.. stops halfway.  Need this to test scanner.  Anyone with helpful advice?

    Hey mwright286!
    Sorry to hear you're having a problem with your Envy and ePrint! Let me see if i can address the issues you brought up here. HP support for printers is 24x7, if you are receiving a message otherwise you may be dialing the wrong number or selecting the wrong options through the prompts.
    As for the ePrint issue you're having, if the printer's Web services has somehow been reset and the printer gave you a new code to setup ePrint with, unfortunately that address is not available again for 6 months. Make sure you don't turn web services off and then back on unless necessary as this will reset the email address.
    If your printer is having alignment issues though, it is very possible that there is a hardware problem with the printer. Try following this document. If you are still having trouble with the alignment then you will want to call support at 1-800-hpinvent.
    Hope this helps!
    If I have solved your issue, please feel free to provide kudos and make sure you mark this thread as solution provided!
    Although I work for HP, my posts and replies are my own opinion and not those of HP.

  • Ipod just keeps connecting/disconnecting. any thoughts?

    here's the story. my ipod died. i upgraded to itunes 7. still was not working, i go to apple and get a refurbished one. the new one keeps connecting/disconnecting. when i open my computer, it shows it just blinking like its there, then its not. does not show in itunes, but half the time says do not disconnect.
    here's where it gets weird. the USB port runs other devices fine. i plugged my ipod into a friends PC and could put music on it. i plugged my friends ipod into my PC and it shows up fine. i've swapped the ipod USB cord with my friend and it still does the same thing. so its not the ipod, its not my comp. and its not my itunes. anyone even want to attempt? i'm at my wits end here.

    Try forcing the iPod into Disk Mode using the instructions in this Apple support document.
    Putting iPod into Disk Mode
    If you can successfully do that, it should keep the iPod mounted on your PC long enough for you to perform a restore of it via iTunes.
    Restoring iPod to factory settings
    B-rock

  • Keep airdrop open?

    Is there any way to keep airdrop open?  My wife's computer on the other side of the room, for example, I can see no problem in Airdrop.  As soon as she closes the finder window that's displaying the Airdrop though she disappears from my Airdrop list.  Is the only way around this to open an Airdrop finder window, then minimize it 'forever'?  It would be just convenient to not have to walk over to her computer every time I want to transfer a file, open Airdrop, then walk back and transfer.
    Or am I missing something?
    Thanks.

    Well, the intention was that Airdrop would be a temporary, ad-hoc file transfer method. In fact, that's exactly what it does - it doesn't use any existing network connections (wired / wireless) but instead creates its own wireless link to the destination computer.
    If you're permanently on the same network as someone else, and have a trusted connection, you only have to set up file sharing once, and can then create a server or folder shortcut in your Dock or desktop. You don't have to authenticate each time. Or, as I say, use the dropbox folder in the Public folder, to avoid having to authenticate.
    Or use DropCopy or DropBox, if you'd prefer
    Matt

  • IPhone 4s keeps connecting and disconnecting from my new Macbook Air 2013

    Ok I've been having this problem, I recently got an 11 inch Macbook Air 2013 and after I try connecting my iPhone 4s it keeps connecting and disconnecting every 1-2 seconds. I already check the community, I know this subject has been asked many times. Nothing worked out though. My cable cord must be fine because it works perfectly on my PC. I updated the OS and iOS to their latest firmware and still nothing. Whenever I try opening iTunes I get this message saying " iTunes could not connect to this iPhone. This device is no longer connected. " Please if anyone fixed this issue I would appreciate some help. Thanks in advance.

    I just solved it, I hope this helps everyone who is experiencing the same problem. Apparently the iPhone seems to charge normally and connect to iTunes if the iPhone battery is over 60%-70%. This must be a power issue the MBA has.

Maybe you are looking for

  • Can't install windows azure storage sdk on windows phone 8

    From Visual studio 2013 ultimate, I opened Nuget package manager console and typed following command for my windows phone 8 solution: install-package windowsazure.storage And I got the following error: install-package : Could not install package 'Mic

  • How to put an xml element in the header field?

    Hello friends, My requirement is like I've a particular element that needs to be printed on the header filed for ex --dept_no and dept_name in the header field...please let me know how.. Thanks

  • Configuring oracle data source in a jboss/linux environment

    Hello I am facing problems to establish connection type 4 with a JBoss 5.1.0 my Data Source is the following : <datasources> <local-tx-datasource> <jndi-name>jdbc/ilogDataSource</jndi-name> <connection-url>jdbc:oracle:thin:@127.0.0.1:1521:XE</connect

  • Preparing "Read Only" CDs

    I am wondering if there is any way in Leopard to burn a CD containing various pdf files, that can only be read, not printed nor copied. Not sure if this is something that can be done within the Mac OS itself, or if specialty 3rd party software is req

  • Weee weee weee, Gotta mouse in ur pocket? I do. Please help with trackpad..

    Trackpad not working. Hardware or software problem? Received an estimate to repair track pad for 200 bucks. The iBook is not even worth that much. Is there any way to make sure this is not a software problem? One think I noticed is that I have no Tra