Oracle8 ODBC Driver and VC++5.0

From: ss <ss_at_tree.com>
Date: Tue, 28 Apr 1998 21:43:03 -0700
Message-ID: <6i4mft$d1l$1_at_supernews.com>



Hi,
I am trying to access Oracle8 database from a VC++ 5.0 program using ODBC. I have Windows NT 4.0, Oracle8 database.
In VC++ 5.0 I am using CRecordSet class to derive my specific classes e.g. CTableConfiguration.I am using Oracle ODBC driver 8.0.3.0.0. ( m_TRANSACTIONFILEPATH is the class member of CTableConfiguration class which corresponds to the field in the database. The Configuration table has only one field of type text named TransactionFilePath) Here follows what I have found ...
If I use the following code

     m_nDefaultType = forwardOnly;
    TRY

          Open();
          AddNew();
          m_TRANSACTIONFILEPATH="C\\YYY";
          Update();//Exception Occurs Here
          Close();
    }
CATCH (CDBException, e)     {     }

END_CATCH
I got an exception where e.m_strError = {"Function sequence error"} and e.m_strStateNativeOrigin =
{"State:S1010,Native:0,Origin:[Microsoft][ODBC Driver Manager]"}

The above exception occurs when it tried to "Update()" the database. The Error is obvious, as I have opened a forwardOnly cursor type I think I cannot Insert a record in the database.

I found that if i open the database as forwardOnly I can see the records. Then I tried to open the database as snapshot, which I thought should allow me to Insert records.But when I tried to "Open()" the database, it failed.

I use the same above code and with m_nDefaltType = snapshot. I got an unhandled exception. From The callback list I found that, it has thrown an exception in the function CRecordSet::VerifyCursor() and the reason it has given is "Snapshot support requires ODBC's static cursor model". Apparently the Oracle ODBC driver 8.0.3.0.0 is somehow not supporting static cursor model.

NOTE : In Article ID Q141716 from Microsoft Article Name :: PRB: Oracle Driver Does Not Support Dynaset, I found with Oracle7 ODBC driver, it is not possible to open a dynaset CRecordSet, however it was possible to open a snapshot.

With Oracle8 I am getting the same type of error with even snapshot type of CRecordSet. I am trying to figure out the above problem for the last 4 days and have failed to find out any solution.

I will be obliged if any one can find out what may be wrong with the Oracle ODBC driver 8.0.3.0.0 and how to overcome the above problem. I have also tried the Oracle Driver 8.0.3.0.2 and am getting the same result.

Please reply (also) at my email address : koushikdg_at_hotmail.comWith Regards Koushik Received on Wed Apr 29 1998 - 06:43:03 CEST

Original text of this message