Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #7736

Re: DBServer - saving changes without Commit during app crash

From "Jamal Assaf" <someone@example.com>
Newsgroups comp.lang.clipper.visual-objects
Subject Re: DBServer - saving changes without Commit during app crash
Date 2015-02-10 17:47 -0500
Organization Aioe.org NNTP Server
Message-ID <mbe1p5$prl$1@speranza.aioe.org> (permalink)
References <dd71ba2e-31e2-43f7-8ef9-f1f189ccef76@googlegroups.com>

Show all headers | View raw


DBServer does not have a "Rollback" feature like SQL.  You probably can 
implement it yourself by creating a PreUpdateBufferArray and trap any errors 
using an errorblock sequence. If any errors occur during the fieldput 
operations, rollback the changes by writing back the PreUpdateBufferArray to 
the same record that just got updated.

Note: DBServer:ConcurrencyControl should be set to CCNONE and you must 
handle record lock/unlock.

Jamal

"Robert Pope"  wrote in message 
news:dd71ba2e-31e2-43f7-8ef9-f1f189ccef76@googlegroups.com...

Hi,

I have an app that is attempting to make updates to a DBServer. An exception 
is being thrown during a FieldPut, which does not get handled and results in 
a application crash. Commit() is not being called.

The problem that I am having is that any pending change in the DBServer, on 
any fields that are written to prior to the failing one, on the same record, 
are being saved.

I have found that the record is being saved by Axit() on DBServer during app 
teardown. The following line specifically:

         (SELF:wWorkArea)->(VODBCloseArea( ))

Is there a way to stop the record being updated? I only want the update to 
occur if I have called Commit(). 

Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

DBServer - saving changes without Commit during app crash Robert Pope <cooeee@gmail.com> - 2015-02-10 05:39 -0800
  Re: DBServer - saving changes without Commit during app crash "Jamal Assaf" <someone@example.com> - 2015-02-10 17:47 -0500
  Re: DBServer - saving changes without Commit during app crash Martin <spam@spam.spam> - 2015-02-11 15:55 +0000
  Re: DBServer - saving changes without Commit during app crash "Dirk (Belgium)" <dirk.dot.herijgers@pbprojects.dot.be> - 2015-02-12 08:20 +0000
  Re: DBServer - saving changes without Commit during app crash Robert Pope <cooeee@gmail.com> - 2015-02-13 02:14 -0800

csiph-web