Oracle error 1002 and 3114

my program is running smooth all the while, out of sudden it hit ora-1002 error subsequently hit ora-3114.
as i know the 1002 is cursor out of sequence, and 3114 is oracle not connect... what is the possible to link up this 2 error together?

this is part of my code...
sqlstmt.len = sprintf((char *) sqlstmt.arr,
"SELECT * from table");
EXEC SQL PREPARE edccnt3 FROM :sqlstmt;
EXEC SQL DECLARE edccnt_c3 CURSOR FOR edccnt3;
EXEC SQL OPEN edccnt_c3;
EXEC SQL FETCH edccnt_c3 into :max_txn_time_year, :last_txn_time_year;
if (max_txn_time_year > last_txn_time_year) {
     sqlstmt.len = sprintf((char *) sqlstmt.arr,     
"SELECT * from table1 where xxx);                    
} else {
sqlstmt.len = sprintf((char *) sqlstmt.arr,     
"SELECT * from table1 where xxx); }
          EXEC SQL CLOSE edccnt_c3;
sprintf(buf_stg, "SQLSTMT=[%s].", (char *) sqlstmt.arr);
log_msg(1, buf_stg);
EXEC SQL PREPARE edccnt2 FROM :sqlstmt;
EXEC SQL DECLARE edccnt_c2 CURSOR FOR edccnt2;
EXEC SQL OPEN edccnt_c2;
EXEC SQL FETCH edccnt_c2 into :min_txn_time_stg;
if ((sqlca.sqlcode == ORA_SUCCESS ) && (cnt == 0)) {
last_txn_time_stg[18] = 0x00;
else if (sqlca.sqlcode != ORA_SUCCESS ) {
/*error happen here*/
sprintf(buf_stg, "Failed with oracle error code %d", curr_eqptype, sqlca.sqlcode);
log_msg(1, buf_stg);
continue;
}

Similar Messages

  • Where can find Oracle error code and message?

    Where can find Oracle error code and message?

    http://otn.oracle.com/pls/db92/db92.to_toc?pathname=server.920%2Fa96525%2Ftoc.htm&remark=docindex
    That would be the "Error Messages" manual.

  • Oracle Error Code and Message for Query Timeout

    Hi,
    I need to catch the oracle error code and message for query timeout.
    I am using Oracle 9i and could not find any relevant error code/message
    for query timeout in Oracle Error Messages.
    If anyone has encountered such error messages, please let me know the
    Oracle Code or Error message.
    Thanks & Regards,
    Kanjana

    Fly is correct in that Oracle will normally let a query run forever in the absense of a user profile or dbms_resource setting that limits a users (query) resouce usage.
    The errors returned for these condition would probably vary but errors ORA-02092 "exceeded session limit on CPU usage, you are being logged off" and ORA-02093 "exceeded call limit on CPU usage" might be of interest.
    But for distributed queries Oracle does impose a time limit. See Oracle error ORA-02049 "timeout: distributed transaction waiting for lock"
    HTH -- Mark D Powell --

  • Oracle error code and description

    Gurus,
    Is there a distinct list of oracle error code with description(in excel or txt,csv format) , the requirement is to convert most of generic oracle messages into user defined messages and store it in a XML.
    Regards
    R
    Edited by: Darthvader-647181 on Aug 11, 2010 8:00 AM

    HareeshGhanta wrote:
    Hi,
    Thank you.I am looking for some additional information like Cause and Action also to be printed out.Is there any way we can achieve this.
    Regards
    Sounds like you are trying to re-invent the wheel.
    What's wrong with the message text as supplied by oracle?  Those messages are universally known and understood -- well, at least by people who actually read them vs. simply dumping them to a forum.  Why would you want to obfuscate them with your own text?
    As for "cause and action", if one has the error code emitted by oracle, there are boat load of web sites that already replicate the same information that oracle itself supplies:
    oracle:dwdev$ oerr ora 12154
    12154, 00000, "TNS:could not resolve the connect identifier specified"
    // *Cause:  A connection to a database or other service was requested using
    // a connect identifier, and the connect identifier specified could not
    // be resolved into a connect descriptor using one of the naming methods
    // configured. For example, if the type of connect identifier used was a
    // net service name then the net service name could not be found in a
    // naming method repository, or the repository could not be
    // located or reached.
    // *Action:
    //   - If you are using local naming (TNSNAMES.ORA file):
    //      - Make sure that "TNSNAMES" is listed as one of the values of the
    //        NAMES.DIRECTORY_PATH parameter in the Oracle Net profile
    //        (SQLNET.ORA)
    //      - Verify that a TNSNAMES.ORA file exists and is in the proper
    //        directory and is accessible.
    //      - Check that the net service name used as the connect identifier
    //        exists in the TNSNAMES.ORA file.
    //      - Make sure there are no syntax errors anywhere in the TNSNAMES.ORA
    //        file.  Look for unmatched parentheses or stray characters. Errors
    //        in a TNSNAMES.ORA file may make it unusable.
    //   - If you are using directory naming:
    //      - Verify that "LDAP" is listed as one of the values of the
    //        NAMES.DIRETORY_PATH parameter in the Oracle Net profile
    //        (SQLNET.ORA).
    //      - Verify that the LDAP directory server is up and that it is
    //        accessible.
    //      - Verify that the net service name or database name used as the
    //        connect identifier is configured in the directory.
    //      - Verify that the default context being used is correct by
    //        specifying a fully qualified net service name or a full LDAP DN
    //        as the connect identifier
    //   - If you are using easy connect naming:
    //      - Verify that "EZCONNECT" is listed as one of the values of the
    //        NAMES.DIRETORY_PATH parameter in the Oracle Net profile
    //        (SQLNET.ORA).
    //      - Make sure the host, port and service name specified
    //        are correct.
    //      - Try enclosing the connect identifier in quote marks.
    //   See the Oracle Net Services Administrators Guide or the Oracle
    //   operating system specific guide for more information on naming.

  • SQL Error 3113 and 3114

    Hi all
    I am getting Sql error 3113, system logs are below:
    i checked tablespaces are having enough space.
    can anybody tell what is this prob
    SQL error 3114 . Work processes in reconnect status       
    SQL error 3113 . Work processes in reconnect status       
    SQL error 3113 . Work processes in reconnect status       
    SQL error 3113 . Work processes in reconnect status       
    Operating system call recv failed (error no. 73 )         
    Perform rollback                                          
    Perform rollback                                          
    Program RM07DOCS manually terminated by user LINFIN       
    Call of function NiRead failed, RC: -006                  
    Work process has left reconnect status                    
    Work process has left reconnect status                    
    Terminal 00046 in status DISC                             
    Perform rollback                                          
    Delete session 003 after error 004                        
    Error calling the central lock handler                    
    Request (type DIA) cannot be processed                    
    > Unable to reach central lock handler                    
    Request (type DIA) cannot be processed                    
    Request (type DIA) cannot be processed                    
    Request (type DIA) cannot be processed                    
    Request (type DIA) cannot be processed                    
    Request (type DIA) cannot be processed

    Hello,
    Well, Is the above error is happening during the offline backup? What is the impact on the system because of the above error? Is any transaction fails?
    The above error could be because of the following
    1. Network issue
    2. wrong client version. If you are SAP Kernel which  is compatible with client 9i, then i suggest to install the latest version of the client. Ofcourse client version shouldn't be more than the version of the oracle server software.
    3. and there could be other possible reasons like some error in the alert log, resource issue.
    Regards,
    Madhukar

  • Receive oracle errors 12560 and/or 12545 under windows xp ...

    last monday, 9.10.06, some changes inside the active directory where done by our AD/admin. since then the logon fails to one spec. application, called tocom, written in sql/windows of co. gupta, only from windows xp clients. windows2k clients still can logon. nothing has changed on the database server. either the xp client receives an ora-12560 error, if the client uses the ip/address of file tnsnames.ora, or an ora-12545 error, if using the host/name entry there. but tnsping or using sqlplus from any xp clients works fine with the same database, as well the logon of an other application, written as well in sql/windows, to another database/server. so only the logon via application tocom fails from xp clients since then with the named errors. any idea? thanks, bye, he.

    thanks for the advise. have in tnsnames both entries...
    TCM.TOCOM_VS = (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(Host=TOCOM_VS) (Port=1526))(CONNECT_DATA=(SID=TCM)(SERVER=DEDICATED)))
    TCM.TOCOM_VS2 = (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(Host=141.11.61.1) (Port=1526))(CONNECT_DATA=(SID=TCM)(SERVER=DEDICATED)))
    with the host name TOCOM_VS and with the ip/address. both fail since monday 9.10.06 but only for xp clients. logon on entry Host=TOCOM_VS fails with error 12545, logon to entry Host=141.11.61.1 fails with error 12560. but on the same client both tnsping and sqlplus can work fine with the same database. have created 2 logfiles of utility filemon.exe of co. sysinternals, spooling any file-call of the logon ot failing application tocom. this shows that the xp client calls a file dnsapi.dll, which the 2k client does not. from then on both logs differ and the xp log soon runs into the errror. any more ideas, please ? thanks, bye, he.

  • Oracle List of Error codes and messages

    Hi,
    In our application we are planning to use sqlloader to load a huge amount of data into the database. However, to parse the log file we need a list of Oracle error codes and messages that are commonly encountered while loading data using sqlloader. Does anyone know where to get such a list?
    Thanks

    In our application we are planning to use sqlloader to load a huge amount of data into the database. However, to parse the log file we need a list of Oracle error codes and messages that are commonly encountered while loading data using sqlloader. Does anyone know where to get such a list?I don't know where to get such a list, but for a start you could search the log for the words "Error" and "ORA-"

  • All oracle errors in a table

    Oracle 11.2.0.1
    Windows 7 Home Premium
    I want to create a table which should have below columns and values :
    ORA Varchar2(20)
    Cause Varchar2(100)
    Action Varchar2(150)
    This table should have all the ORAs with their causes and suggested action(s).
    Can you please give me such a link for this?
    Thanking you.

    user12050217 wrote:
    Hello Sir,
    Can you please confirm that a good oracle installation in windows have oraus.msg ? After searching on different links, i found that oraus.msg is for *nix OS, oracle provides oraus.msb for windows.  Kindly confirm my understanding.
    I need this table because our application team has asked our DBA team to provide them a complete oracle error code, causes and action column, so that they can use in their daily purpose. They are designing a utility in which user will simply input oracle error number and output will be fetched by this table (in case there is no internet connectivity and DBA is on the leave). So that they can talk DBAs over phone that we are getting such and such error and this is cause and action from your table.
    Please help me in this regard.
    Thanks and Regards,They are re-inventing the wheel. Oracle has already provided that utility. It's call 'oerr' and is fully documented and supported. Do they also want to re-write sqllpus? expdp/impdp? sqlloader? How about the dbms_* utilities?

  • Oracle errors in a table or view

    Hi,
    Is there any oracle table or view with all the oracle error numbers and error messages
    from ORA-00000 till ORA-36804.
    Please let me know.
    Thanks in advance.
    Sreenath.

    There isn't a table, but you can create your own easily. This script displays them all but you could just as easily insert them into a table:
    DECLARE
       err_msg          varchar2(4000);
    BEGIN
    FOR err_num IN 0..36804 LOOP
       err_msg := SQLERRM(-err_num);
       if instr(err_msg, 'Message ' || err_num || ' not found;') = 0 then
          dbms_output.put_line(err_msg);
       end if;
    END LOOP;
    END;
    /Notice that this doesn't print errors that have no associated message.

  • I tried to restore my iphone and got a message saying an error 1002 occured, what do i do?

    I tried to restore my iphone and got an error 1002. What does that mean and how can i fix my phone?

    Click here >  iOS: Resolving update and restore alert messages
    Click 1002 on that page.

  • Error to connect oracle 10g client and designer BO 4.0

    hello,
    I try to connect oracle 10g client and designer BO 4.0.
    I created an ODBC connection to function in the administration tools of data sources but I can not connect once in designer.
    I tried using the driver directly oracle designer 10 but I have the same error that is this:
    DBD: ORA-12154: TNS: connection identifier specified could not be resolved
    someone there had the same concerns?
    cordially

    Hi,
    so it looks like that your TNSNAMES.ORA file isn`t properly configured. Thats why you can connect with the IDT to your Oracle Database.
    Your DBA`s should sent you the correct TNSNAMES.ORA file or the entry for your DB prior. After the tnsping works, you will be able to use the IDT properly.
    Regards
    -Seb.

  • AutoConfig is exiting with status 1 And ORACLE error 6502 in afpodbinit

    Hi Experts,
        Excuse me for trying to brief the Issue in such manner which may not be apt. or appear stupid to many Experts.   But I am newbie to Oracle Apps !
      After registering the  EBS R12.1 Vision, DB version 11.2.0.3.0   with OID 11.1.1.6  successfully with  $FND_TOP/bin/txkrun.pl   Before that Registered EBS Instance with OID
       as part of Integrating EBS R12 with OAM-OID 11g according to  (ID :1309013.1)
        Once i updated  these profile options i.e  "Applications SSO Type" profile option to “SSWA w/SSO”  and“Applications SSO Login Types” profile option to   BOTH ,   AND
      Applications SSO Auto Link User profile option to “Enabled” And “Applications SSO Enable OID Identity Add Event” profile option to “Enabled”.
      And than it requyire the EBS tier to be restarted Once i restarted it  Than the following  Issues  Occured.
       1.  As i specified the provisiontype value to 1 which means that  the user that's got created in OID should be populated in fnd_user table in EBS But this is not happening
            as the User that i 've created with the ODSM is not propagated to fnd_user table when i verified it with the following query
                   select USER_NAME, CREATION_DATE from fnd_user where creation_date > (SYSDATE - 1);
                       The Output : no rows selected
    2.  The EBS Login page become inaccessible that is the Login Page goes blank
    3.  opmn managed are running fine But when i checked the status of adcmctl got the following error,
    You are running adcmctl.sh version 120.17.12010000.5
    ORACLE error 6502 in afpodbinit
    Cause: afpodbinit failed due to ORA-06502: PL/SQL: numeric or value error: character to number conversion error
    ORA-06512: at "APPS.FND_GLOBAL", line 1939
    ORA-06512: at "APPS.FND_GLOBAL", line 2309
    ORA-06512: at "APPS.FND_GLOBAL", line 2447
    ORA-06512: at line 1.
    The SQL statement being executed at the time of the error was: begin fnd_global.bless_next_init('FND_PERMIT_0000'); fnd_global.initialize(:session_id, :user_id, :resp_id, :resp_appl_id, :security_group_id, :site_id, :login_id, :conc_login_id, :prog_appl_id, :conc_program_id, :conc_request_id, :conc_priority_request, :form_id, :form_application_id, :conc_process_id, :conc_queue_id, :queue_appl_id, :server_id); fnd_profile.put('ORG_ID', :org_id); fnd_profile.put('MFG_ORGANIZATION_ID', :mfg_org_id); fnd_profile.put('MFG_CHART_OF_ACCOUNTS_ID', :coa); fnd_profile.put('APPS_MAINTENANCE_MODE', :amm); end; and was executed from the file &ERRFILE.
    Internal Concurrent Manager status could not be determined.
    adcmctl.sh: exiting with status 0
    even though
    adopmnctl.sh status give the following output.
    You are running adopmnctl.sh version 120.6.12010000.5
    Checking status of OPMN managed processes...
    Processes in Instance: VIS_ebs.ebs.oracle.com
    ---------------------------------+--------------------+---------+---------
    ias-component                    | process-type       |     pid | status
    ---------------------------------+--------------------+---------+---------
    OC4JGroup:default_group          | OC4J:oafm          |  100242 | Alive  
    OC4JGroup:default_group          | OC4J:forms         |  100173 | Alive  
    OC4JGroup:default_group          | OC4J:oacore        |  100021 | Alive  
    HTTP_Server                      | HTTP_Server        |   99964 | Alive
    4. when i run the autoconfig  it got Failed with these error
        AutoConfig is exiting with status 1
        also the following i observed in the adconfig log file.
    [PROFILE PHASE]
      AutoConfig could not successfully execute the following scripts:
        Directory: /oracle/VIS/apps/tech_st/10.1.3/perl/bin/perl -I /oracle/VIS/apps/tech_st/10.1.3/perl/lib/5.8.3 -I /oracle/VIS/apps/tech_st/10.1.3/perl/lib/site_perl/5.8.3 -I /oracle/VIS/apps/apps_st/appl/au/12.0.0/perl -I /oracle/VIS/apps/tech_st/10.1.3/Apache/Apache/mod_perl/lib/site_perl/5.8.3/i686-linux-thread-multi /oracle/VIS/inst/apps/VIS_ebs/admin/scripts/adexecsql.pl sqlfile=/oracle/VIS/inst/apps/VIS_ebs/admin/install
          afwebprf.sql            INSTE8_PRF
        Could you please suggest whats could be Issue here.   Also posting the contents of /etc/hosts file  Although these is no Issue with the Apps & DB listener.
    [root@l]# cat /etc/hosts
    127.0.0.1    localhost.localdomain    localhost
    192.168.12.6     iam.oracle.com  iam   (WHICH IS THE EBS node)
    192.168.12.13     OAM.oracle.com  OAM (which is the OAM node)
    Thanks & Regards
    Priya

    Hi Hussein, 
    Thanks for the suggested Docs
    I 've gone through the Docs that you 've suggested And based on that  made a Comprehensive analysis of the Issues and comes up with these findings even though still short of the resolution
    Kindly see  the following and suggest. 
    1. The Docs [ID 1109247.1]   suggested to  Remove the value of profile option ' Initialization SQL Statement .
         Please see the current Value of it and if you could give your thoughts
    SHORT_NAME                             
    NAME               
    LEVEL_SET         
    CONTEXT                        
    VALUE
    FND_APPS_INIT_SQL      
    Initialization SQL Statement - Oracle
    Application     
    OFA                             
    BOTH
    FND_APPS_INIT_SQL      
    Initialization SQL Statement - Oracle
    Application      
    SQLGL                          
    BOTH
    FND_APPS_INIT_SQL      
    Initialization SQL Statement - Oracle
    Responsibility   
    BIS_FIN                         
    BOTH
    FND_APPS_INIT_SQL      
    Initialization SQL Statement - Oracle
    Responsibility     
    BIS_FIN-19121522              
    BOTH
       Also when i query the home_url from icx_sessions The home_url column of the table are BLANK. even though it's there in the context file which is verified by this output.
    grep login $CONTEXT_FILE
             <login_page oa_var="s_login_page">http://ebs.oracle.com:8000/OA_HTML/AppsLogin</login_page>
        Therefore i quried to check the whether the related  Tablespace are full. It is not  FULL also there is no Issue of space TEMP tablespace either,
        Please see the APPS_SSO related profile values after dating those values the EBS login url ISSUE  Occured. as I already mentioned that in the First POST.
    SHORT_NAME                                  NAME                    LEVEL_SET              CONTEXT                             VALUE
    FND_APPS_INIT_SQL           Initialization SQL Statement - Oracle    Application            OFA                                    BOTH
    FND_APPS_INIT_SQL           Initialization SQL Statement - Oracle    Application             SQLGL                                 BOTH
    FND_APPS_INIT_SQL           Initialization SQL Statement - Oracle    Responsibility           BIS_FIN                              BOTH
    FND_APPS_INIT_SQL           Initialization SQL Statement - Oracle    Responsibility          BIS_FIN-19121522                      BOTH
    APPS_SSO               Applications SSO Type            Site                                                                     SSWA_SSO
    APPS_SSO               Applications SSO Type            User        PROFILEOPTIONS                                                  BOTH
    APPS_SSO_ALLOW_MULTIPLE_ACCOUN Applications SSO Allow Multiple Accounts Site                                                         BOTH
    TS
    APPS_SSO_AUTO_LINK_USER        Applications SSO Auto Link User        Site                                                           Enabled
    APPS_SSO_CHANGE_PWD_URL        Application SSO Change Password URL    UnDef                      UnDef
    APPS_SSO_FORGOT_PWD_URL        Application SSO Forget Password URL    UnDef                      UnDef
    APPS_SSO_HINT_COOKIE_NAME      Applications Single Sign On Hint Cookie                         Site                                    BOTH
                       Name
    APPS_SSO_LDAP_SYNC           Application SSO LDAP Synchronization    Site                                                               BOTH
    APPS_SSO_LDAP_SYNC           Application SSO LDAP Synchronization    User        GUEST                                                 BOTH
    APPS_SSO_LDAP_SYNC           Application SSO LDAP Synchronization    User        PROFILEOPTIONS                                        BOTH
    APPS_SSO_LDAP_SYNC           Application SSO LDAP Synchronization    User        SYSADMIN                                              BOTH
    APPS_SSO_LINK_SAME_NAMES       Link Applications user with OID user wit UnDef        UnDef
                       h same username
    APPS_SSO_LINK_TRUTH_SRC        Applications SSO Linking Source of Truth Site                                                            BOTH
    APPS_SSO_LISTENER_TOKEN        Applications SSO Partner Application Lis UnDef        UnDef
                       tener Token
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        Site                                                               BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        MHUNT                                                  BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        PTULL                                                     BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        MEMERY                                                    BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        RKARMER                                                   BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        CABLACKWELL                                               BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        DBAKER                                                    BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        SCRAWFORD                                                 BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        WJEFFREY                                                   BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        PROFILEOPTIONS                                            BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        PROCESS_OPS                                               BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        FAVERY                                                    BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        FBRAMER                                                   BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        GUEST                                                     BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        DAEVANS                                                   BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        RGRANT                                                     BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        MNOOT                                                     BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        PPARKINSON                                               BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        SYSADMIN                                                  BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        PGARRER                                                   BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        RDUNNE                                                     BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        PDESMOND                                                  BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        CPARKER                                                   BOTH
    APPS_SSO_LOCAL_LOGIN           Applications SSO Login Types        User        CHMARTIN                                                   BOTH
    APPS_SSO_MODPLSQL_URL           Applications SSO MOD_PLSQL Url        UnDef        UnDef
    APPS_SSO_OID_IDENTITY           Applications SSO Enable OID Identity Add Site                                                              Enabled
                    Event
    APPS_SSO_POSTLOGOUT_HOME_URL   Applications SSO Post Logout URL     UnDef        UnDef
    APPS_SSO_USER_CREATE_UPDATE    Applications SSO User Creation and Updat Site                                                                    Y
                       ion Allowed
       Waiting to hear from you.  Please suggest
    Thanks
    Priya

  • Using PreparedStatement and the Oracle Error ORA-1000

    Hi,
    I have a question about PreparedStatement objects that is not so simple to explain for me. What I would like to know is: if I use a PreparedStatement following traditional and generic steps:
    1- PreparedStatement pStmt = Connection.prepareStatement(sQuery);
    2- pStmt.setXXX(i,j);
    n - pStmt.setXXX(i,j);
    n+1 - ResultSet rs = pStmt.executeQuery();
    n+2 - while(rs.next()){ ... retrive ResultSet data  ... }
    n+3 - rs.close()
    n+4 - back to point number 2
    and at the end (as you can see in the point numbered n+4), instead of closing the PreparedStatement pStmt using the close() method, I reuse the PreparedStatement pStmt comeing back to the point numebr 2 and setting again all its parameters with new values ... then ... what heppens in the Oracle database ? Has been the cursor (so the mamory area), associated to my PreparedStatement object pStmt, duplicated or is it the same ?
    I know that Java allows you to do this kind of operations with PreparedStatement, and I know that in tha Java Documentation is explained to follow this strategy to optimize the execution time because in this way the same PreparedStatement is precompiled and prepared only once. But if I do a for loop following the steps explained before, after many iterations I have the error "ORA-1000: maximum open cursors exceeded". This error is the reason of my question. Does this error means that it's mandatory to close a PreparedStatement always, otherwise if you reuse it without closing it then the corresponding database cursor will be duplicated ? If it is so, then I think this is a contradiction with official java documentation ...
    I'm using Oracle8i (version 8.1.7) and Oracle JDBC Thin Driver (Windows NT) for use with JDK 1.2.x. Moreover, in my database istance the parameter "maximum open cursor" is equal to 800 ...
    Thank you very much for suggestions :-)

    There is no need to close a prepared statement or its resultset for every iteration.
    After the first iteration in a loop, all subsequent executions of it will close the previous resultset. By adding close() method, you are making one extra costly call to the DB for no reason.
    Following is the sample code.I know what you are saying. In fact at the beginning I wrote my code in the same way of your sample (see the code of my first post at the begin of this page).
    But doing so, after thousand iterations of the loop, I had "Oracle Error ORA-1000 : maximun open cursor exeeded" even if in my database istance the parameter "maximum open cursor" is equal to 8000.
    At this moment in my code, for each iteration, I close the PreparedStatement and in this way I don't have anymore the error :-((
    So it seems that only in theory we can reuse a preparedStatement without closing it. In fact if we see the oracle system table "$open_cursor" (as Konrad Pietzka suggest me) we can find that, for each interation,
    at our line code "rs = pstmt.executeQuery();" correspond a new cursor in the database: this means that for each method "pstmt.executeQuery()" the database open a new cursor and do not use the previous one as it should.
    I posted a question two months ago to search if someone had the same problem (it seems that Konrad Pietzka had the same situation) and was able to explain me what is the cause.
    The only reason I found by myself for this problem, is that probably the Oracle JDBC Thin Driver for Windows NT/2000 has some bugs... but I'm not sure ...
    Thank you very much for you time !!
    bye :-))
    Fidalma

  • Oracle error ORA-00600 when using Oracle 10g and Sun One Web Server 6.1

    I have a java application that was running under Solaris 8 and Oracle 9i. I am trying to get it up and running on a new server that is configured with Solaris 9 and Oracle 10g. Whenever the application tries to connect to the database it receives the following error: ORA-00600 [ttcgcshnd-1][0]. My research indicates that this is an internal Oracle error that represents a low level unexpected condition. I have looked through my configuration for the Web Server and I have not been able to determine the cause of this problem. My DBA tells me that we have the latest patch installed for Oracle! Has anyone encountered this problem before? Any help would be greatly appreciated!

    If the problem is also present in a SWING app, i.e. outside the web server, then it is porbably something external to the webserver.
    I think you should ensure that the driver and database are compatible with each other. It is very likely that you need a new jdbc driver for the new database.
    download from here http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/htdocs/jdbc101020.html
    try the ojdbc14.jar

  • Connection Errors between Oracle 8 Client and Oracle 8.1.6 EE

    Our current application has been developed using PowerBuilder 6.5 and Oracle 8.1.5. Since PB 6.5 does not have a "native driver" for 8.1.5, we have used their driver for Oracle 8.0.5 for Net8 connectivity to the server. Everything works fine.
    Recently, I downloaded the current version of Oracle 8.1.6 EE from Technet to try out the compatibilty of our software with the next version of 8I, it failed. The error seems to be somewhere between the 8.0.5 Oracle Client Software and the downloaded Oracle 8.1.6 EE Server software. Some how we have lost the ability to declare cursors. I tried declaring a cursor in a procedure through SQL*Plus and it failed their as well. I have even tried the Oracle 8.0.6 Client, with same results.
    Has anyone seen this? If so, what should I do?
    Thanks,
    Jason

    HOW TO SUPPORT TWO-TASK COMMON ERRORS - 1012295.102
    Troubleshooting
    ===============
    Two-task common errors are generally RDBMS related issues, but could be caused by a problem with SQL*Net, or an application (i.e. Pro*C).
    ORA-03106
    ======== Possible reasons for the ORA-03106 errors include:
    1. Incompatibilities between the client application and the RDBMS server.
    For example, version incompatibilities, or a client trying to use a feature not supported by the database kernel.
    2. When using database links or gateways.
    3. Network or SQL*Net problems.
    4. Corruptions.
    5. PL/SQL - language related.
    check the NLS_LANG variable on the client and server.

Maybe you are looking for