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
 

 

Question regarding catalog tables

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

New User


Joined: 27 Nov 2007
Posts: 1
Location: HYDERABAD

PostPosted: Sat Dec 01, 2007 11:23 am    Post subject: Question regarding catalog tables
Reply with quote

I have a question regarding catalog tables...

which of the following will affect the catalog tables??
A) ALTER
B)DROP
C)SELECT
Back to top
View user's profile Send private message

zero

New User


Joined: 01 Dec 2007
Posts: 21
Location: Hyderabad

PostPosted: Sat Dec 01, 2007 6:56 pm    Post subject: Reply to: Question regarding catalog tables
Reply with quote

Hi,
catalog tables are nothing but system tables which are used by DB2 to store metadata (Information about tables - the different columns in a table, their definitions, their properties like unique key, nullability ... , tablespaces, indexes, views and other objects).

Below are a few of the DB2 catalog tables :

SYSTABLES :
SYSTABSTATS :
SYSCOLUMNS :
SYSINDEXES :
SYSKEYS :
SYSFOREIGNKEYS

above tables are used for different purposes.

now, coming to your question,

ALTER - this is used to modify the structure of the table. like, adding a column, increasing the size of CHAR field,
...
so, i think, ALTER will definitely affects catalog tables.

DROP - dropping a table means all the information of the table is removed from the before said tables. so, DROP also affects catalog tables.

SELECT - SELECT statement just uses the catalog information in catalog tables while fetching data from tables. so, it does not affect catalog tables.

hope this helps,

thanks,
zero
Back to top
View user's profile Send private message
stodolas

Active Member


Joined: 13 Jun 2007
Posts: 632
Location: Wisconsin

PostPosted: Sat Dec 01, 2007 10:43 pm    Post subject:
Reply with quote

Select can also be used to affect the system tables

SELECT INTO SYSIBM.SYSCOLUMNS

would definetly affect that table.
Back to top
View user's profile Send private message
Debraj Roy

New User


Joined: 20 Dec 2007
Posts: 1
Location: Bangalore

PostPosted: Mon Jan 28, 2008 2:31 pm    Post subject: @Steve
Reply with quote

Can you explain what is the function of this statement:??

SELECT INTO SYSIBM.SYSCOLUMNS

Warm Regards,
Debraj
Back to top
View user's profile Send private message
stodolas

Active Member


Joined: 13 Jun 2007
Posts: 632
Location: Wisconsin

PostPosted: Mon Jan 28, 2008 6:17 pm    Post subject:
Reply with quote

Bah, I referenced it wrong for DB2. That is a programming statement.
http://publib.boulder.ibm.com/infocenter/db2luw/v8/index.jsp?topic=/com.ibm.db2.udb.doc/admin/r0000994.htm

see: http://expertanswercenter.techtarget.com/eac/knowledgebaseAnswer/0,295199,sid63_gci1054790,00.html
for what I was getting at.
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 QUESTION: RETURN CHANNEL pahiker CA Products 21 Thu Apr 20, 2017 12:31 am
No new posts The Last Two Question For You To Ask ... CaptBill Mainframe Interview Questions 0 Fri Apr 14, 2017 5:42 am
No new posts Data replication from multiple Db2 ta... kishpra DB2 9 Mon Mar 27, 2017 9:58 pm
No new posts Unable to catalog a gdg dataset resid... Shovan JCL & VSAM 7 Fri Mar 24, 2017 2:24 pm
No new posts SPUFI -- Joining 3 tables – data in... Sysaron DB2 2 Wed Mar 08, 2017 4:18 am


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