Previous Topic: REORGNext Topic: REORG Parameter


REORG Syntax

►►── REORG ─┬──────────────────────────────────────────────────┬──────────►
            ├─ setup-options ─┬─────────────────────────┬──────┤
            │                 │ setup-execution-options │      │
            │                 └ ESTIMATE workfile sizes ┘      │
            │                                                  │
            ├─ execution-options ──────────────────────────────┤
            ├─ CLEANUP ─┬──────────┬─┬──────────┬──────────────┤
            │           │ NODELETE │ └ NOUNLOCK ┘              │
            │           └ DELETEALL┘                           │
            │                                                  │
            ├─ STATUS REPORT ONLY ─────────────────────────────┤
            └─ ESTIMATE workfile sizes ─────┬────────┬─────────┘
                                            └ SUBMIT ┘

Expansion of setup-options

►►──┬─ DBNAME source-db-name ───────── USING source-subschema-name ──┬────►
    │                                                                │ 
    └─ SEGMENT source-segment-name ┬───────────────────────────────┬─┘
                                   └─ USING source-subschema-name ─┘

 ►───┬────────────────────────────────────────────────┬───────────────────►
     │          ┌──────── , ──────┐                   │
     └── AREA ──▼── area-name ────┴───────────────────┘

 ►── RELOAD INTO target-database-name ────────────────────────────────────►
 ►───┬─────────────────────────────────────────────────┬──────────────────►
     └─── USING target-subschema-name ─────────────────┘

 ►───┬─────────────────────────────────────────────────┬──────────────────►
     └─── DMCL target-dmcl-name ───────────────────────┘

   ┌─────────────────────────────────────────────────────────┐
 ►─▼─┬─────────────────────────────────────────────────────┬─┴────────────►◄
     ├─── DIVIDE PROCESSING ─┬─ 1 ◄──┬─┬─ WAY ──┬──────────┤
     │                       └─ n ───┘ └─ WAYS ─┘          │
     ├─── REUSE workfiles ─────────────────────────────────┤
     ├─── GENERATE DBKEYS files ───────────────────────────┤
     ├─── as SORTEXIT ─────────────────────────────────────┤
     ├─── SHARE ───────────────────────────────────────────┤
     ├─── NOTIFY notify-interval ──────────────────────────┤
     ├─── DELETE old workfiles ────────────────────────────┤
     ├─── OVERFLOW PERCENT nnn ────────────────────────────┤
     └─── OVERFLOW CACHE nnnnnnnn ──┬────┬─────────────────┘
                                    ├ KB ┤
                                    ├ MB ┤
                                    └ GB ┘

Expansion of setup-execution-options

    ┌─────────────────────────────────────────────────────────┐
►►──▼┬──STOP AFTER ─┬─ CLEANUP ◄──┬────────────────────────┬──┴─────────►◄
     │              ├─ SETUP ─────┤                        │
     │              ├─ UNLOAD ────┤                        │
     │              └─ RELOAD ────┘                        │
     └─── CREATE ──┬─ NO ◄────┬───────┬─────────────┬──────┘
                   ├─ UNLOAD ─┤       └─ WORKFILES ─┘
                   ├─ RELOAD ─┤
                   └─ ALL ────┘

Expansion of execution-options

    ┌─────────────────────────────────────────────────────────┐
►►──▼┬──STOP AFTER ─┬─ CLEANUP ◄──┬────────────────────────┬──┴─────────►◄
     │              ├─ UNLOAD ────┤                        │
     │              └─ RELOAD ────┘                        │
     ├─── SUBMIT ──────────────────────────────────────────┤
     └─── CREATE ──┬─ NO ◄────┬───────┬─────────────┬──────┘
                   ├─ UNLOAD ─┤       └─ WORKFILES ─┘
                   ├─ RELOAD ─┤
                   └─ ALL ────┘