RelationalDBDesign RelationalDBDesign

Physical Backups  «Prev 

Logging and no Logging Mode Implications in Oracle

Direct-load or Direct Path Load

Direct-load, also known as direct path load, is a process of formatting Oracle data blocks and writing the data blocks directly to the database files. You can, for example, choose to do direct-load operations with SQL*Loader. The direct-load does not compete with other users for database resources so it can usually load data faster.
Oracle SQL*Loader is flexible and offers many options that should be considered to maximize the speed of data loads. These include:
  1. Use Direct Path Loads - The conventional path loader essentially loads the data by using standard insert statements. The direct path loader (direct=true) loads directly into the Oracle data files and creates blocks in Oracle database block format. The fact that SQL is not being issued makes the entire process much less taxing on the database. There are certain cases, however, in which direct path loads cannot be used (clustered tables). To prepare the database for direct path loads, the script

    must be executed.
  2. Disable Indexes and Constraints. For conventional data loads only, the disabling of indexes and constraints can greatly enhance the performance of SQL*Loader.
  3. Use a Larger Bind Array. For conventional data loads only, larger bind arrays limit the number of calls to the database and increase performance. The size of the bind array is specified using the bindsize parameter. The bind array's size is equivalent to the number of rows it contains (rows=) times the maximum length of each row. Also see the columnarrayrows and streamsize parameters.
  4. Use ROWS=n . For conventional data loads only, rows specifies the number of rows per commit and is related to bindsize. Issuing fewer commits will enhance performance, and the larger rows parameter affects performance (see benchmark below).
  5. Use Parallel Loads. Available with direct path data loads only, this option allows multiple SQL*Loader jobs to execute concurrently.
    $ sqlldr control=first.ctl  parallel=true direct=true 
    $ sqlldr control=second.ctl parallel=true direct=true 
  6. Use Fixed Width Data. Fixed width data format saves Oracle some processing when parsing the data. The savings can be tremendous, depending on the type of data and number of rows.
  7. Disable Archiving During Load. While this may not be feasible in certain environments, disabling database archiving can increase performance considerably.
  8. Use unrecoverable. The unrecoverable option (unrecoverable load data) disables the writing of the data to the redo logs. This option is available for direct path loads only.