Re: Hot and Cold backups



Randy Harris wrote:
> "Sybrand Bakker" <postbus@xxxxxxxxxxxxxxxxx> wrote in message
> news:p1idd193h6kf8a29fa4mokfspedf6effr8@xxxxxxxxxx
>> On Thu, 14 Jul 2005 19:29:41 GMT, "Randy Harris"
>> <randy@xxxxxxxxxxxx> wrote:
>>
>>> Thanks for the explanation. As I posted earlier, I was under the
>>> impression that shutdown immediate was safe, no transactions
>>> could be lost. I understand now that is not the case. If I want
>>> to be certain that no data is lost, I need to use shutdown
>>> transactional.
>>
>> Obviously you still don't understand what is going on. You won't
>> loose transactions. An uncommitted transaction is simply not a
>> transaction. And of course, using shutdown transactional, will
>> make sure you can't shut down the database, ever.
>>
>>
>> --
>> Sybrand Bakker, Senior Oracle DBA
>
> Well then I sure wish someone would explain it so that I can
> understand.
>
> 1 - server receives a DML statement from a client application, it
> begins processing it, it will be committed when completed
> 2 - before the statement is finished processing a shutdown
> immediate is issued
> 3 - Oracle halts processing of the DML statement and rolls back the
> data 4 - Oracle server discards that DML statement and shuts down
> the database 5 - the data in that DML statement is lost
>
> Please, please explain which part of this is wrong.
> Are you saying that it is the responsibility of the client
> application to know that the transaction was never committed?

Your statement 1 is incorrect.
A DML statement will NOT be committed when it completes.
It is the applications responsibility to define what it wants to see as a
Transaction, Logical Unit of Work, or whatever name you want to give to the
SET of DML statements you want to be either committed together or
roll-backed together.
Sure, the SET can be just 1 statement, but not necessaraly so.
Consider a banking application, where you want to subtract an amount from
one account and, within the SAME Logical Transaction, add this amount to
another account.
So yes, the application (developer) decides when to commit/rollback.

HTH,

--
Jeroen


.



Relevant Pages

  • Re: Hot and Cold backups
    ... >>that shutdown immediate was safe, ... An uncommitted transaction is simply not a transaction. ... > Sybrand Bakker, Senior Oracle DBA ... - server receives a DML statement from a client application, ...
    (comp.databases.oracle.server)
  • Re: Session ending shutdown problem
    ... massively long shutdown time, you will have to rethink what it means to "shut down". ... and start routing everything to it instead of the databases. ... this process starts gets appended to the transaction file instead. ... Of course I can detect the QueryEndSession and EndSession messages. ...
    (microsoft.public.vc.mfc)
  • Re: Session ending shutdown problem
    ... shutdown, something that was enormously useful during program ... and start routing everything to it instead of the databases. ... this process starts gets appended to the transaction file instead. ... Of course I can detect the QueryEndSession and EndSession messages. ...
    (microsoft.public.vc.mfc)
  • Re: Session ending shutdown problem
    ... event log which is created very early and shut down at the very end ... shutdown the log is not closed ... and start routing everything to it instead of the databases. ... this process starts gets appended to the transaction file instead. ...
    (microsoft.public.vc.mfc)
  • Re: Error-handling Question
    ... > SELECT and fetches you really don't care about transaction ... commit/rollback or somehow end the transaction at some point. ... a long running process that has autocommit turned off & only does selects ...
    (perl.dbi.users)