DB2 Load utility most people think that it is the Admin task. But it is a developer task too. Load utility highly useful when the volume of data is more.
Advertisements
Top Interview Questions
INSERT and Import gives better performance. Access Control to Load Utility. You need these two accesses:
- SYSADM
- DBADM
SQL State Error 5U014
During Load operation, if there are any protected columns, you will get 5U014 error. So you need LBAC access to your session id.
Types of Storage in DB2
Storage in Db2 Explained
The Important Modes on Load Utility
- INSERT
- REPLACE
- RESTART
- TERMINATE
INSERT
- The INSERT mode, just append the new rows in the Table. It will not DELETE any rows.
REPLACE
- It DELETEs all the rows, and inserts new rows in Table. The definition of Table and Indexes will not be changed.
- ** One of the best interview question
RESTART
- It restarts from the previously committed point. That means, where it stopped previously.
TERMINATE
- The Terminate mode is little tricky. It Terminates till the point where it initially started.
- It brings all the objects and indexes to normal.
- The LOAD TERMINATE issues on LOAD REPLACE, then it keeps in a state that, Table data truncates. That means, you can see empty Tables.
- The LOAD TERMINATE will not remove backup pending state.
- The LOAD TERMINATE issues on LOAD INSERT, The Table will retain all its original rows. That means the Table will be as before when you start LOAD INSERT.
DEFFERRED
- It means the indexes will not build during a load operation. But, these can be build using REBUILD mode.
Related Posts