View previous topic :: View next topic
|
Author |
Message |
hari korrapati
New User
Joined: 27 Mar 2011 Posts: 4 Location: India
|
|
|
|
Hi,
I have one cenario like how to empty a table by using LOAD utility in db2 v9.1. |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1788 Location: Bloomington, IL
|
|
|
|
Load an empty data set. |
|
Back to top |
|
|
PeD
Active User
Joined: 26 Nov 2005 Posts: 459 Location: Belgium
|
|
|
|
.. empty file..
Exact : like this :
Code: |
//LOAD EXEC PGM=DSNUTILB,PARM=(DB2N,'EMPTY.LOAD')
//SYSUT1 DD DISP=(NEW,PASS),DSN=&&SYSUT1
//SORTOUT DD DISP=(NEW,PASS),DSN=&&SORTOUT
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSREC DD DUMMY
//SYSIN DD *
LOAD DATA INDDN SYSREC LOG YES REPLACE
EBCDIC CCSID(00500,00000,00000)
INTO TABLE CCCCC.XX_XXX_XXX "
/*
//*--------------------------------------------------------------------* |
|
|
Back to top |
|
|
GuyC
Senior Member
Joined: 11 Aug 2009 Posts: 1281 Location: Belgium
|
|
|
|
if it's the only table in the tablespace!! |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1788 Location: Bloomington, IL
|
|
|
|
GuyC wrote: |
if it's the only table in the tablespace!! |
If it's not, shoot the DBA who designed it. |
|
Back to top |
|
|
GuyC
Senior Member
Joined: 11 Aug 2009 Posts: 1281 Location: Belgium
|
|
|
|
Akatsukami wrote: |
GuyC wrote: |
if it's the only table in the tablespace!! |
If it's not, shoot the DBA who designed it. |
IBM catalog? Default Explain-tables? QMF tables,...
I think IBM is the only one who doesn't follow their own recommendations ;) |
|
Back to top |
|
|
daveporcelan
Active Member
Joined: 01 Dec 2006 Posts: 792 Location: Pennsylvania
|
|
|
|
Quote: |
If it's not, shoot the DBA who designed it.
|
It depends on the application.
We have test 'databases' used by our development staff that have 600 tables and only three tablespaces.
This design is much more flexible and efficient space wise.
Just don't use the Dummy Load Replace. |
|
Back to top |
|
|
|