-
rollback data from the tables
Hi I am loading data from csv files to oracle table using sql loader. and i am loading it one by one. is there a way to roll back the data already loaded from one csv if there is a data error.
-
Rollback is only possible inside a transaction.
Pablo (Paul) Berzukov
Author of Understanding Database Administration available at amazon and other bookstores.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
-
sorry i did not understand.. can u please explain.
I used ERRORS=0 as command line paramter for sql loader so that not data is loaded when a data error has occured. I am automating the script so that it loads from the begining the next time. I am not sure of how to avoid duplicate records being inserted. pls advice
-
Use a staging table, truncate it before loading. Once you get it right move the data from staging to final-destination table.
The "transaction" concept is at the foundation of rdbms technology, it wouldn't hurt to read a little about it.
Pablo (Paul) Berzukov
Author of Understanding Database Administration available at amazon and other bookstores.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|