Help | Site Map
Connecting Tech Pros Worldwide
Reply
 
LinkBack Thread Tools
  #1  
Old October 1st, 2008, 05:06 AM
Newbie
 
Join Date: Oct 2008
Posts: 2
Default concatenation of rows

I have the following table contents:
ID kEYWORD
-------- ----------------------
1 AB
1 AC
1 AD
2 XX
2 YYY


I need to convert this to the following output:

ID kEYWORD
-------- ----------------------
1 AB,AC,AD
2 XX,YYY


How can I do this?
I don't like to use procedures, functions or any anonymous blocks
it should be a simple statement starting with select
Reply
  #2  
Old October 2nd, 2008, 06:00 AM
debasisdas's Avatar
Moderator
 
Join Date: Dec 2006
Location: Bangalore ,India
Posts: 6,870
Default

You need to use DECODE for all that.
Reply
  #3  
Old October 3rd, 2008, 05:07 AM
Newbie
 
Join Date: Oct 2008
Posts: 2
Default

Quote:
Originally Posted by debasisdas
You need to use DECODE for all that.
can u frame the exact query with decode
Reply
  #4  
Old October 18th, 2008, 03:12 PM
amitpatel66's Avatar
Moderator
 
Join Date: Mar 2007
Location: India
Age: 24
Posts: 2,028
Default

Please try and post back inc ase of any issues
Reply
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles