Register | Login

DB2 Load Utility

Posted by jyothsnav 2458 days ago (Editorial)

Like the Import utility, the LAOD utility is designed to read data directly from an external file and store it in a specific table. However, unlike when the import utility is used, when the Load utility is used the table to which data is to be copied must already exist in the database before the load operation is initiated.


Syntax:


LOAD FROM [filename] OF [DEL|ASC|IXF]


SAVECOUNT [savecount]


[INSERT|REPLACE|RESTART|TERMINATE] INTO [Tablename]


[NONRECOVERABLE]


 NOTE: Various options were there for LOAD utility which we will discuss in the next article


INSERT - data is appended to the target table


REPLACE - any existing data is deleted and then the new data is loaded


RESTART - any previous load operation failed or was terminated is continued, starting from the last recorded point of consistency. If this option is used, the load command should be identical to the previous load operation


TERMINATE - the current load operation is terminated, and any changes made are backed out if the load operation being terminated is performed with insert option. If specified for replace option, data is truncated.


LOAD FROM dept.ixf OF IXF SAVECOUNT 1000


INSERT INTO department



Who Voted for this Article



YourWiz.com, is a website that will allow everyone to share their knowledge, tip or information through community micro blogging.