Skip to Main Content
  • Questions
  • Flashback versin and flashback transaction

Breadcrumb

Question and Answer

Tom Kyte

Thanks for the question, Maruf.

Asked: April 15, 2010 - 1:26 pm UTC

Last updated: April 15, 2010 - 2:48 pm UTC

Version: 10.0.1

Viewed 1000+ times

You Asked

Hello Tom,

What is the difference between flashback version query and flsahback transaction query?
What are the things both will give?

and Tom said...

http://docs.oracle.com/cd/B19306_01/appdev.102/b14251/adfns_flashback.htm#sthref1476


flashback version query - returns all instances of a row(s) over a period of time. It lets you ask "show me all of the committed versions of this record(s) between X and Y points in time"

If you updated and committed the record 5,000 times between X and Y, you'll get 5,000 records.

If you didn't update the record, you'll get 1 row back.



flashback transaction - returns the DML necessary to logically undo the work of a given TRANSACTION. If a transaction inserted a record, updated 3 records and deleted 5 records - flashback transaction query would show you need to insert 5 records (to undelete), update three records (to un-update), and delete a record (to un-insert)



Rating

  (1 rating)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Maruf Malek, April 22, 2010 - 3:44 pm UTC

Thanks a lot TOM..