I'm running systemtest that updates a oracle schema. I need to reset the whole scheme between runs.

Is there an easy way to do this in oracle 12. I have looked at flashback but it doesn't seem to be the right way to go.

  • You can flashback a table or the whole database, but not a schema. If rewinding the whole database to an earlier state is acceptable, flashback is the easiest way to do it. – Balazs Papp May 18 '16 at 13:27

perhaps you looked at flashback queries, what you need are restore points.

  1. Create a guaranteed restore point before starting test
  2. Perform test, measure, save results
  3. startup mount the db, flashback database to restore point
  4. drop and re-create guaranteed restore point.
  5. lather. rinse. repeat

It really doesn't get easier than that. I do it multiple times a week and have essentially reduced it to a small script and keep doing this against my dev db.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.