How will we know that all the records have been inserted into our Oracle database table?
Question: We will be inserting 10 million records into a table in our Oracle database. How will we know that all the records have been inserted into our table?
Unless we're missing something, the easiest way to do this is to count the number of records in your destination table before the insert and then count them again after the insert. This is done by issing the SQL command SELECT COUNT(*) FROM my_table;
You don't say what you're using to do the insert but if you're using tools like SQL*Loader, or Import/Impdp these also generate log files which can be examined after the insert for any errors.
If you're writing a bespoke program to do this then ensure that you write any errors to a log file.
You might also want to review our Oracle SQL tutorials
. Also see our Oracle training
page for information about formal training courses both on-line and in person.
Click here to post comments
Join in and write your own page! It's easy to do. How? Simply click here to return to Oracle Questions.