On January 27th, this site will be read-only as we migrate to Oracle Forums for an improved community experience. You will not be able to initiate activity until January 30th, when you will be able to use this site as normal.

    Forum Stats

  • 3,889,534 Users
  • 2,269,755 Discussions


Row not getting updated, No errors thrown


I am using the Timesten ODBC interface for C to program an application which updates some rows in a timesten DB based on inputs received.

It prepares the sql statement using SQLPrepare and then fires the query using SQLExecute.

What is happening is sometimes the rows are NOT getting updated even though no errors where thrown.

Does the function SQLExecute wait for update statement to complete before returning a success message or is it fire and forget.

Is its possible that the queries my application is firing getting timed out , but since the function returned a success message the issue was not caught.

What possible precautions can i take to avoid this kind of errors.

Any help is appreciated.



  • ChrisJenkins-Oracle
    ChrisJenkins-Oracle Senior Director, In-Memory Technology United KingdomMember Posts: 3,412 Employee
    edited Jun 14, 2016 9:36AM

    SQLExecute is completely synchronous; when it returns the target rows (if any) will have been updated. Of course those updates are not visible to queries from any other session until the UPDATE(s) have been committed.

    I see several possibilities for the behaviour that you report:

    1.   You are UPDATEing via one connection and querying via a different connection and you have not committed the updates so the queries do not see the updated rows.

    2.   There is some mistake in the UPDATE statement(s) such that it is not actually updating any rows. This could be a SQL issue or a programming issue e.g. related to bind variables etc.

    3.   There is some mistake in the queries that you are issuing such that they are not properly finding the correct rows. This could be a SQL issue or a programming issue e.g. related to bind variables etc.

    What value is returned in the 'pcrow' argument when you call SQLRowCount() against the statement handle used for the UPDATE immediately after SQLExecute returns? When executing DML you should always check SQLRowCount() afterwards to see who many rows were affected. This might give you a clue as to where the problem lies.


This discussion has been closed.