Page 1 of 1

ApplyUpdates does not work?

Posted: Mon 30 Aug 2010 10:33
by Thomas Dannert
We have a problem with the actual ODAC Version. In our Service Application the Data to Oracle is only written or viewable in Oracle SQL Developer wen we stop the Service (OraSession close). In a previous Version of our Service with an older Version of ODAC the Data is written and viewable directly. We testet the same with SDAC and in SDAC the ApplyUpdates Statement works correctly.

By Example:

Code: Select all

OraSession.ExecSQL('...', []);
OraSession.ApplyUpdates; //<-- Does not work
Connection Parameters:

Code: Select all

OraSession := TORASession.Create(nil);
with OraSession do
begin
    Options.ConvertEOL := False;
    Options.DateLanguage := 'German';
    Options.DateFormat := 'DD.MM.YYYY HH24:MI:SS';
    Options.Charset := FCharSet;
    Server := FDataBase;
    Username := FUsername;
    Password := FPassword;
    AutoCommit := True;
    ThreadSafety := True;
    Connected := True;
end;

Posted: Tue 31 Aug 2010 08:05
by AlexP
Hello,

The ApplyUpdates method is used to write all pending cached updates from all active datasets available in this database connection.

To save the result after executing OraSession.ExecSQL you need to execute the OraSession.Commit metod.

Posted: Tue 31 Aug 2010 16:04
by Thomas Dannert
AlexP wrote:Hello,

The ApplyUpdates method is used to write all pending cached updates from all active datasets available in this database connection.

To save the result after executing OraSession.ExecSQL you need to execute the OraSession.Commit metod.
Thanks Alex for your answhere.