1 Reply Latest reply: Jul 28, 2013 11:42 PM by michaelrozar17 RSS

    delete statement on table

    pawii

      what would happen if i fire a delete statement on a column of  an employee table just after the database is started?

      kindly tell me the sequence in which this event would happen

       

      1.parse tree will be created

      2.deleting of data from datafiles

      3.writing of sql statement in archived log file

      4.updation of control file ckpt

      5.updation of data file header

      6.bringing the data blocks to data buffer

       

      according to me the sequence will be 6,1,3,4,5,2

        • 1. Re: delete statement on table
          michaelrozar17

          I would not say this as the exact steps, in general it would be like below. Suggestions/modifications are welcome..


          Once a DML statement is issued:

          1. Memory is allocated from the SQL Area in SGA

          2. A hash value is generated in the memory for the query

          3. Syntax and Semantic checks are done

          4. Data Blocks brought to buffer cache ( if not present in the Buffer previously)

          5. Undo Segments created, Redo is generated for this Undo activity

          6. Data Blocks in buffer cache is modified

          7. Redo's generated

           

          If commit is issued then

          8. SCN is generated for the transaction

          9. Redo logs are written from Redo buffer to Online Redo logs

           

          If CKPT occurs then

          10. CKPT writes the SCN to Control file and to Data file header

          11. DBWr writes the dirty blocks