Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

TABLESPACE IS NOT EMPTY

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
apsar.kogatam
Warnings : 1

New User


Joined: 27 Jun 2008
Posts: 33
Location: CHENNAI

PostPosted: Wed Feb 03, 2010 3:28 pm    Post subject: TABLESPACE IS NOT EMPTY
Reply with quote

Hi Team,

I am using the below jcl to delete all the data from table and to load with new data.eventhough the table is empty which i am trying to load is giving the error 'TABLESPACE IS NOT EMPTY'.I have used the below control card to load the table.Can you please advice me how to proceed furthur.
c
ontrol card:

LOAD DATA INDDN SYSREC01 RESUME NO INTO TABLE
DA53.T535702
(


)
Back to top
View user's profile Send private message

guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Wed Feb 03, 2010 3:33 pm    Post subject:
Reply with quote

Hello Apsar,

You cant use resume no with Nonempty Tablespace.In order to delete all the rows from tablespace & load new data useload Replace job.

Let me know if you need further help
Back to top
View user's profile Send private message
apsar.kogatam
Warnings : 1

New User


Joined: 27 Jun 2008
Posts: 33
Location: CHENNAI

PostPosted: Wed Feb 03, 2010 3:42 pm    Post subject:
Reply with quote

Hello Gupte,

Can u just brief me what is Non empty tablespace.By name i can understand that the tablespace is not empty to hold the new data.Am i correct here?And also i tried the job before with Load replace but the tables data which i am not intended also getting deleted.Please adivice me.
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Wed Feb 03, 2010 3:48 pm    Post subject:
Reply with quote

Hello Apsar,

Non Empty Tablespace: Atleast one table contained in Tablespace contained Data

Secondly Load Replace will delete the data of all the tables of that particular Tablespace. If you want to replace data of specific table of
Tablespace you need to delete all the rows in the table, and then use LOAD with RESUME YES. For
example, assume that you want to replace all the data in PNASCMOD.TSEMP1
without changing any data in PNASCOMD.TSEMPA. To do this, follow these steps:
1. Delete all the rows from PNASCMOD.TSEMP1 by using the following SQL
DELETE statement:
Code:
EXEC SQL
DELETE FROM PNASCMOD.TSEMP1
ENDEXEC

Tip: The mass delete works most quickly on a segmented table space.
2. Use the LOAD job that is shown in the following figure to replace the rows in
that table.
Code:
LOAD DATA RESUME YES
INTO PNASCMOD.TSEMP1
(....
)
Back to top
View user's profile Send private message
apsar.kogatam
Warnings : 1

New User


Joined: 27 Jun 2008
Posts: 33
Location: CHENNAI

PostPosted: Wed Feb 03, 2010 4:55 pm    Post subject: Reply to: TABLESPACE IS NOT EMPTY
Reply with quote

Hello Guptae,

Thankyou so much its working now.
Back to top
View user's profile Send private message
apsar.kogatam
Warnings : 1

New User


Joined: 27 Jun 2008
Posts: 33
Location: CHENNAI

PostPosted: Wed Feb 03, 2010 5:03 pm    Post subject:
Reply with quote

Hi Guptae,
The load is working fine for me for all the tables which i require but for some of the tables in sysout of Job the //UTPRINT statements are missing.

I have used the below for all

//UTPRINT DD SYSOUT=*

Can you please advice me what could be the reason for missing UTPRINT ststements in sysout.
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Wed Feb 03, 2010 5:18 pm    Post subject:
Reply with quote

Hello Apsar,

UTPRINT contain message from DFSORr.If any utility requires a sort, it executes DFSORT. Messages from that program are sent to UTPRINT So
might be load of those table did nt require sort.
Back to top
View user's profile Send private message
apsar.kogatam
Warnings : 1

New User


Joined: 27 Jun 2008
Posts: 33
Location: CHENNAI

PostPosted: Wed Feb 03, 2010 5:20 pm    Post subject:
Reply with quote

thanks alot
Back to top
View user's profile Send private message
Ajay Baghel

Active User


Joined: 25 Apr 2007
Posts: 205
Location: Bangalore

PostPosted: Thu Feb 04, 2010 7:18 pm    Post subject: Reply to: TABLESPACE IS NOT EMPTY
Reply with quote

Hi Guptae

Adding to what has already been said above, I want to know what is the standard practice for backup of table or tablespace in both the scenarios:

1) Load with Replace -- works on entire tablespace. If this option is used, i need to take backup of entire table space. Am I right?

2) Load with No Replace and RESUME Yes -- works on specific tables in tablespace tablespace. So if i am using this option, do i need to take backup of those tables only?

Am i right in saying this?


Thanks and Regards,
Ajay
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 Image Copy of a tablespace that conta... Robin Sulsona DB2 4 Thu Jun 02, 2016 1:47 am
This topic is locked: you cannot edit posts or make replies. how to find if file is empty or not. abdulrafi DFSORT/ICETOOL 5 Tue May 17, 2016 4:39 pm
No new posts IBMHPU - Tablespace and Imagecopy chaitanya bharath DB2 1 Fri Apr 15, 2016 5:54 pm
No new posts Query on Image Copy Tablespace and QU... vickey_dw DB2 3 Fri Oct 23, 2015 10:55 am
No new posts UNLOAD from Image Copy Tablespace wit... alluri12 DB2 5 Wed Sep 23, 2015 7:00 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us