IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Finding Primary key for bulk of tables


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
banuradha

New User


Joined: 20 Dec 2006
Posts: 19
Location: India

PostPosted: Wed Dec 27, 2006 12:16 pm
Reply with quote

Hi all,

I have requirement to list primary keys for a bulk of tables and is that possible in REXX? or anyother way.

Thanks
Banu
Back to top
View user's profile Send private message
DavidatK

Active Member


Joined: 22 Nov 2005
Posts: 700
Location: Troy, Michigan USA

PostPosted: Thu Dec 28, 2006 1:44 am
Reply with quote

What kind of tables are you talking about?
Back to top
View user's profile Send private message
banuradha

New User


Joined: 20 Dec 2006
Posts: 19
Location: India

PostPosted: Thu Dec 28, 2006 10:27 am
Reply with quote

DavidatK wrote:
What kind of tables are you talking about?


Its DB2 tables, I got an answer for it.if u know someother way please share it

the answer is

Code:
SELECT NAME
FROM
SYSIBM.SYSCOLUMNS
WHERE TBNAME = 'Table_name'
AND   TBCREATOR = 'Tb_creator '
AND   KEYSEQ > 0
ORDER BY KEYSEQ ASC
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts Finding and researching jobs All Other Mainframe Topics 0
No new posts VB to FB - Finding LRECL SYNCSORT 4
No new posts Query on edit primary command CLIST & REXX 5
No new posts Query on edit primary command CLIST & REXX 1
No new posts Finding Assembler programs PL/I & Assembler 5
Search our Forums:

Back to Top