View previous topic :: View next topic
|
Author |
Message |
mailsaurabh.tripathi
New User
Joined: 22 May 2008 Posts: 56 Location: hyderabad
|
|
|
|
WHEN I' TRYING TO INSERT DATA IN MY TABLE, I'M GETTING FOLLOWING ERROR:
DSNT408I SQLCODE = -904, ERROR: UNSUCCESSFUL EXECUTION CAUSED BY AN
UNAVAILABLE RESOURCE. REASON 00C900A3, TYPE OF RESOURCE 00000200, AND
RESOURCE NAME DEDBS01 .STU
STU IS MY TABLESPACE, which is existing< even the table is existing |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
This is a theme that has many many threads in this forum.
you need to look at the reason code.
Besides, if the table did not exist, you would have received a different message. |
|
Back to top |
|
|
Prasanthhere
Active User
Joined: 03 Aug 2005 Posts: 306
|
|
|
|
I guess your tablespace or index space is check pending status. You have to reset the checkpending flag
Try this in a JCl you should be getting rid of this error
SET TABLESPACE dbname.tsname NOCHECKPEND |
|
Back to top |
|
|
ruodeer
New User
Joined: 06 Jul 2007 Posts: 58 Location: home
|
|
|
|
you can use DB2 command -DIS DATABASE(yourdatabase) to show what the status your tablespace is ,then you will find your TS is in abnormal status due to your resource is unavailable. |
|
Back to top |
|
|
sriram.mukundan
New User
Joined: 20 Nov 2007 Posts: 28 Location: chennai
|
|
|
|
Hi,
pls use option 7 ( db2 commands) and enter the following command.
Quote: |
-DISPLAY DATABASE(DBname) SPACENAM(Spacename) |
Ruodeer also mentioned the same. It is Image copy pending state ( Check pending status RECAP )
The following status will be available once u issue the command:
Code: |
DSNT360I -TDB2 ***********************************
DSNT361I -TDB2 * DISPLAY DATABASE SUMMARY
* GLOBAL
DSNT360I -TDB2 ***********************************
DSNT362I -TDB2 DATABASE = DATABASE NAME STATUS = RW,RECP
DBD LENGTH = 4028
DSNT397I -TDB2
NAME TYPE PART STATUS PHYERRLO PHYERRHI CATALOG PIECE
-------- ---- ----- ----------------- -------- -------- -------- -----
Spacename TS RW,RECP
******* DISPLAY OF DATABASE DBANAME ENDED **********************
DSN9022I -TDB2 DSNTDDIS 'DISPLAY DATABASE' NORMAL COMPLETION
*** |
if its RECP mode, then either you can stop the Database and Start database if the DB is meant for testing purpose.
we also had the same issue, we did this only. it was working fine.. but Stop of a database will take more time.
before Stopping the DB pls Ensure that whether the tables are not used by anyone and it is not being used by anyprogram.
Another way is you can drop the tabel, create the table in the TS by specifying the option NOCHECKPEND
I hope this information will help you. |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Ram,
Quote: |
if its RECP mode, then either you can stop the Database and Start database if the DB is meant for testing purpose. |
In my day to day DBA BAU activities, I always recovered the TS.
I never knew, stopping and starting the DB will resolve this. Thanks for the 'wrong' guidance.
Quote: |
before Stopping the DB pls Ensure that whether the tables are not used by anyone and it is not being used by anyprogram. |
Do you think this is possible when TS is recp.
Quote: |
Another way is you can drop the tabel, create the table in the TS by specifying the option NOCHECKPEND |
Good idea to DROP a 'live' table. Try it in your shop once.
Quote: |
I hope this information will help you. |
No is my answer. |
|
Back to top |
|
|
Prasanthhere
Active User
Joined: 03 Aug 2005 Posts: 306
|
|
|
|
Hey,
If you DB admin previlage you can easily reset the checking pending flag through a JCL or your DB adminstrators can easily make it for you. |
|
Back to top |
|
|
sriram.mukundan
New User
Joined: 20 Nov 2007 Posts: 28 Location: chennai
|
|
|
|
Hi Murali,
Quote: |
I never knew, stopping and starting the DB will resolve this. Thanks for the 'wrong' guidance. |
I'm not misguiding or giving a wrong suggestion. I told very specifically if the TS contains only one table and only one TS available for the DB you can Stop and Start again.
Because i had the same issue last week, one of my friend in this forum helped me saying to Stop the DB and start it again. It was working fine. then i can able to insert or update or what ever may be. since we have only table in that database only one table space. so we did like that. Do you think he misguided me.??
Quote: |
Good idea to DROP a 'live' table |
I told very specifically in the beginning if your using for testing purposes you can drop the table and try it once.
or else you can even use this JCL to remove the RECP mode.
Code: |
//*------------------------------------------------------
//* JCL FOR REMOVING COPY PENDING STATUS OF A TABLE
//*------------------------------------------------------
//COPY EXEC DSNUPROC,SYSTEM='SYSTEMNAME'
//SYSIN DD *
LISTDEF COPYLIST INCLUDE TABLESPACE DBNAME.SPACENAME
COPY LIST COPYLIST COPYDDN(XXXCOPY)
SHRLEVEL(CHANGE)
/* |
Or even you can use the following commands in option 7 ( db2 commands)
-Dis util(*)
It will give the UTILID.
and then you can use the following command
-TERM util(utilid)
Hope this information helps. |
|
Back to top |
|
|
|