Parent Table and Child Table



IBM's flagship relational database management system

Parent Table and Child Table

Postby chetan_007 » Mon Jun 22, 2009 10:40 pm

Hi,

Suppose If I want to make some updates in Parent table then I need to update corresponding child tables too.
But, how can I know the child table names associated with parent table in DB2.

Could any one explain me.

Thanks,
Chetan
chetan_007
 
Posts: 24
Joined: Sun Mar 02, 2008 3:22 am
Has thanked: 0 time
Been thanked: 0 time

Re: Parent Table and Child Table

Postby dick scherrer » Mon Jun 22, 2009 11:34 pm

Hello,

If this has not already been provided via an entity relationship diagram of something similar, you should talk with your dba.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Parent Table and Child Table

Postby jitender_2004bhiwani » Fri Nov 20, 2009 12:24 pm

Hello,

when browsing the table using DB2 fileaid, use command 'rbrowse' it will display all parent and child relations for that table.
jitender_2004bhiwani
 
Posts: 10
Joined: Fri Nov 20, 2009 8:42 am
Has thanked: 0 time
Been thanked: 0 time

Re: Parent Table and Child Table

Postby jitender_2004bhiwani » Fri Nov 20, 2009 12:30 pm

see below screens for more help:

QAOS#2 D for DB2 Browse RAVFS2.TVFPAYI_PI SSID: DQA0
COMMAND ===> rbrowse SCROLL ===> CSR
PI_ID PARTITION_NO IMPORT_FILE_ID PI_SUB_TYPE_ID SYSTEM_S
DEC(11,0) SMALLINT DEC(11,0) SMALLINT CHAR(4)
------PRIMARY ------------ -------------- -------------- --------
000001 950. 1 ------------- 5 COMP
000002 3400. 1 ------------- 5 COMP

then press enter and following screen will appear;

QAOS#2 Row 1 to 6 of 23
COMMAND ===>

A one to one or one to many relationship exists.
Use ADD to create a new application relationship or select an existing
relationship definition.
To edit a view: overtype displayed table name with a valid single table
view name.

Line Commands:
S - Select table
I - Relationship Information

CMD Creator Table/View Type
--- -------- ------------------- --------------------------------
_ RAVFS2 TVFACCC_CHARGE_ACC RI - CHILD
_ RAVFS2 TVFBENF_BENEFICRY RI - CHILD
_ RAVFS2 TVFBLKT_BLKLST_TMP RI - CHILD
_ RAVFS2 TVFBLKT_BLKLST_TMP RI - CHILD
_ RAVFS2 TVFCANC_CANC_REQST RI - CHILD
_ RAVFS2 TVFDACC_DEBIT_ACC RI - CHILD
jitender_2004bhiwani
 
Posts: 10
Joined: Fri Nov 20, 2009 8:42 am
Has thanked: 0 time
Been thanked: 0 time

Re: Parent Table and Child Table

Postby dick scherrer » Sat Nov 21, 2009 2:43 am

Hello,

If someone asks a question about file-aid, it is good to provide a file-aid answer.

As most systems to not have file-aid/db2 it is best not to provide solutions that require this product to general questions.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Parent Table and Child Table

Postby enrico-sorichetti » Sat Nov 21, 2009 5:19 pm

see below screens for more help:
the help/answer will be completely useless if the TS does not have the product/tool You are suggesting
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: Parent Table and Child Table

Postby GuyC » Wed Nov 25, 2009 10:14 pm

look in sysibm.sysrels (if the relationship is documented in DB2)
I can explain it to you, but i can not understand it for you.
GuyC
 
Posts: 315
Joined: Tue Aug 11, 2009 3:23 pm
Has thanked: 1 time
Been thanked: 4 times

Re: Parent Table and Child Table

Postby jitender_2004bhiwani » Tue Dec 01, 2009 10:15 am

Dick/enrico,

I agree that the help/answer given by me is completetly useless if the TS does not have DB2 fileaid. But DB2 fileaid is a common product which most of the company (around 95 %) have whoever is using IBM DB2. Also I am suggesting one of the way to find a solution for the user's problem without any concern to what the user have on thier site.

In mainframe world, there are different ways to handle everything which are site specific, so if we will think more about them we won't to be able to help the people.
jitender_2004bhiwani
 
Posts: 10
Joined: Fri Nov 20, 2009 8:42 am
Has thanked: 0 time
Been thanked: 0 time

Re: Parent Table and Child Table

Postby dick scherrer » Tue Dec 01, 2009 10:58 am

Hello,

But DB2 fileaid is a common product which most of the company (around 95 %) have whoever is using IBM DB2.
Where did you get this statistic? Compuware would surely be happy if their fileaid/db2 product was licensed at 95% of the organizations that have db2 :)

In mainframe world, there are different ways to handle everything which are site specific, so if we will think more about them we won't to be able to help the people.
Almost everything (except a product specific question) can be answered by some "standard" solution (see the suggestion from GuyC). Most situations do not require some site-specific product.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Parent Table and Child Table

Postby chetan_007 » Tue Mar 09, 2010 9:37 pm

What are the different version of DB2 are available for mainframes since inception?
Please give me the list of DB2 versions till date. (Also I'm not clear about the tem DB2 UDB - is it related to mainframes DB2)?
chetan_007
 
Posts: 24
Joined: Sun Mar 02, 2008 3:22 am
Has thanked: 0 time
Been thanked: 0 time

Next

Return to DB2

 


  • Related topics
    Replies
    Views
    Last post