Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
how to empty a table by using Load utility

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
hari korrapati

New User


Joined: 27 Mar 2011
Posts: 4
Location: India

PostPosted: Sun May 22, 2011 6:45 pm    Post subject: how to empty a table by using Load utility
Reply with quote

Hi,

I have one cenario like how to empty a table by using LOAD utility in db2 v9.1.
Back to top
View user's profile Send private message

Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1775
Location: Bloomington, IL

PostPosted: Sun May 22, 2011 9:20 pm    Post subject:
Reply with quote

Load an empty data set.
Back to top
View user's profile Send private message
PeD

Active User


Joined: 26 Nov 2005
Posts: 456
Location: Belgium

PostPosted: Mon May 23, 2011 12:41 am    Post subject:
Reply with quote

.. 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
View user's profile Send private message
GuyC

Senior Member


Joined: 11 Aug 2009
Posts: 1281
Location: Belgium

PostPosted: Mon May 23, 2011 12:57 pm    Post subject:
Reply with quote

if it's the only table in the tablespace!!
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1775
Location: Bloomington, IL

PostPosted: Mon May 23, 2011 2:23 pm    Post subject:
Reply with quote

GuyC wrote:
if it's the only table in the tablespace!!

If it's not, shoot the DBA who designed it.
Back to top
View user's profile Send private message
GuyC

Senior Member


Joined: 11 Aug 2009
Posts: 1281
Location: Belgium

PostPosted: Mon May 23, 2011 5:49 pm    Post subject:
Reply with quote

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
View user's profile Send private message
daveporcelan

Active Member


Joined: 01 Dec 2006
Posts: 683
Location: Pennsylvania

PostPosted: Mon May 23, 2011 7:25 pm    Post subject:
Reply with quote

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
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Insert a Row_number into table useit DB2 2 Tue Sep 19, 2017 1:07 pm
No new posts how to see when the last read access ... Mike 1304 DB2 1 Tue Sep 12, 2017 7:52 pm
No new posts BUILD OUTFIL based on condition other... balaji81_k DFSORT/ICETOOL 13 Fri Sep 08, 2017 11:06 pm
No new posts PC (UTF-8) -> z/OS (EBCDIC) -> ... prino All Other Mainframe Topics 4 Fri Sep 01, 2017 1:47 am
No new posts Adding a userid to SMTP Security table Yolanda Harvey JCL & VSAM 1 Sun Aug 13, 2017 6:16 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us