Recently I made a mistake, that, all the tables in my oracle database were dropped (running drop command from SQL Developer tool) in a sequence of all transactions unbeknownst to me that I was dropping tables at the wrong database. Each time I dropped a set of tables, I committed the operations. By the time, I realized that I have dropped the tables at the wrong DB, I was too late to rollback, since it rolled back the last operation only. I searched online as well, and found SavePoints to be the resolution, but I had no savepoints configured. I had the backup of all the tables taken 2 days before, so, I ran scripts from there and made lost changes for the past 2 days. Is there any other way that I take to get my DB state back. I have made it a practice to make savepoints while performing such operations though. But, I am still confused. One who doesn't know about savepoints will lose all the data.
How to rollback all the commits in Oracle DB
1k Views Asked by KnockingHeads At
1
There are 1 best solutions below
Related Questions in ORACLE11G
- Building an sql execution plan history
- how to update the date field for this specific condition using oracle query?
- Insert Into SP in Oracle Sql Developer
- Trying to update an ORACLE 11G DB with C# Asp.net using Oracle Managed Driver.
- Require tool to trace the LInq Queries in Oracle
- Oracle 11g : staging table
- Persist the value of one column in two simultaneous update
- Trigger From Oracle to SQL SERVER
- how to check succeeded and failed sending a message in gsmcomm library
- How to install Oracle XE for windows32 properly?
- use select under case statement
- Merge table in Oracle with delete condition refering to source table
- Oracle 11g to PostgreSQL - CREATE TYPE OBJECT
- Import dmp file created in Oracle 11g (WE8ISO8859P1) to Oracle 11g XE database (AL32UTF8)
- Changing start date for system jobs related to automatic statistics collections in 11g
Related Questions in ORACLE-SQLDEVELOPER
- Android: How to connect oracle database using Android Java code?
- Insert Into SP in Oracle Sql Developer
- Oracle 11g : staging table
- add time (char(8)) to date column
- How can I solve "Got minus one from a read call" in oracle sql developer?
- Call procedure using anonymous block in pl/sql?
- SQL - missing keyword in case when syntax
- String conversion to time
- Return multiple rows from a stored procedure
- Sql Developer conditions from Excel
- SQL - Select multiple fields from multiple tables
- executing a stored proc with output parameter
- Differences in these 2 query
- Select max value from different column in a row in oracle database
- Oracle declaring and Using Dates
Related Questions in DATABASE-ADMINISTRATION
- Windows Authentication - Restrict SQL Server Backend Access
- who writes a DDL - DBA or the developer using the table
- Selecting ticketid with status history
- Oracle DB: delete all the contents
- How to create a "live" feed for two seperate Postgres Instances?
- grant to multiple db using one command
- what is the correct format of a column for store UTC date time
- how to schedule a job on Oracle SQL developer to execute shell command "Java -Jar /Home/JavaFile.jar" each one minute?
- Any ideas on why this query would run so slow?
- Attempting insertion into the row version column "SSMA_TimeStamp". Cannot insert into a row version column
- MongoDB command `compact` is not working
- Can we do table partition in SQL Server 2012 Standard Edition
- query that shows if the tables might need analyze and vacuum
- How to extractvalue of table counts using xml in DB2? (see working Oracle equivalent)
- Data Export of SQL Server table from one server to another / Data Flow task error
Related Questions in ROLLBACK
- combining rollback in two action rails 4
- Symfony2: transactions fail with "There is no active transaction."
- PHP rollback on IBMi db2 doesn't work
- Which git feature should I use for breaking big commit (pushed and reversed) into smaller commits?
- Teradata does it have a ROLLBACK
- It always go to OleDbException
- How to prevent errors when saving multiple models in Laravel 5
- Unexpected Rollback upon saving form
- Dependent rollback among different DAO implementation
- Why are these nested SQL Server transactions throwing a mismatch error if there is a rollback?
- Git Extensions rollback last 2 commits
- What happens to inserted records when a model function returns before it reaches to rollback or complete?
- Entity Framework - Issues in DbContextTransaction.Rollback()
- Rails rollback transaction for bids
- Where will be the message after all attempts to deliver at endpoint in mule rollback exception strategy?
Related Questions in SAVEPOINTS
- DB2 savepoint in stored procedure is invalid
- ActiveRecord, MySQL, and nested transactions -- what's the behavior?
- Is Flink standalone cluster manual restart graceful wrt to job state/processing offset?
- How to get all savepoint states list in mysql
- How to retry transaction after exception in postgreSQL
- Rollback to savepoint doesn't release locks
- Drupal on mysql cluster
- Jdbc check for capability - savepoint release
- In SQL, what happens if you try to rollback to a savepoint from another user?
- Flink, How to create a Sink supported Savepoint?
- Duplicated messages reading via flink savepoints
- Flink: How to persist and recover a ValueState
- Flink savepoint not saving the valuestates
- ora-01086 : save point was not established or invalid
- Using SAVE TRANSACTION SavePointName in a Stored Procedure
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
DDL statements like
dropdo an implicit commit so you cannotrollbackto undrop a table. Nor would a savepoint help you since that only lets you go back to an earlier point in the current transaction.If you have merely dropped a table, assuming you haven't disabled the recycle bin, you can simply do a flashback drop
If you have a more complicated script that is doing more than just dropping tables, you may want to set a restore point prior to running the script. You could then flashback the entire database to that restore point if something goes wrong.