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

Want to display the table like as follows


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
narendra_12d

New User


Joined: 07 Sep 2006
Posts: 7
Location: bangalore

PostPosted: Sat Mar 03, 2007 1:24 am
Reply with quote

hi i have the table like this

TAB X

A B

1 5
2 6
3 7
4 8

this is my table, i want output like as follows...

C D

1 A
3 A
7 B
8 B


please help any body, Thanks in advance...

regards,
narendra.
Back to top
View user's profile Send private message
wanderer

Active User


Joined: 05 Feb 2007
Posts: 199
Location: Sri Lanka

PostPosted: Sat Mar 03, 2007 2:25 am
Reply with quote

So what is the logic used in this display? I mean how does the 1 3 7 8 pattern come?
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Sat Mar 03, 2007 2:47 am
Reply with quote

narendra_12d wrote:
please help any body
Gladly, but you must help us first.
Please do us a favor and look at what you just posted as if you had never seen that table or heard of what it should become. If you can do that, I think you will realize that it makes no sense.
Try to reformat your request with a better example and a logical explanation of what you want.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sat Mar 03, 2007 3:47 am
Reply with quote

Hello,

Please use "real" (or at least descriptive) column names rather than A, B, C, & D. Are these column names in 2 tables?

Is your "result" a new table (TAB Y) or some kind of report?

What "rules" are applied the the input to get the results you want? (Why were 2, 4, 5, & 6 not applied to the "new" table?).

Your post makes perfect sense to you, but not to the rest of us. As Bill said - for us to help, you must help first.
Back to top
View user's profile Send private message
vini_srcna

Active User


Joined: 26 May 2005
Posts: 178
Location: Copenhagen, Denmark

PostPosted: Tue Mar 06, 2007 4:27 pm
Reply with quote

Please get back to us with more information on your logic. What exactly you need. I would suggest to use application program rather than sql for this kind of purpose.
Back to top
View user's profile Send private message
vini_srcna

Active User


Joined: 26 May 2005
Posts: 178
Location: Copenhagen, Denmark

PostPosted: Tue Mar 06, 2007 4:31 pm
Reply with quote

I mean to say use sql in appliction program with some programmic logic to get the desired things.
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 -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Load new table with Old unload - DB2 DB2 6
No new posts Pulling a fixed number of records fro... DB2 2
No new posts Multiple table unload using INZUTILB DB2 2
No new posts Check data with Exception Table DB2 0
No new posts Dynamically pass table name to a sele... DB2 2
Search our Forums:

Back to Top