Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Concatenating multiple columns into one column

AvaAug 6 2009 — edited Aug 6 2009
Hi All,

We have requirement, to concatenate 5 columns into one column.

The data is as follows:

ACOLUMN BCOLUMN CCOLUMN DCOLUMN ECOLUMN
123 012 NULL 010 568
NULL 258 852 215 001
568 395 402 012 NULL

i Would like to combine all columns into column FCOLUMN and the output will be as follows:

FCOLUMN
123012
NULL
568395402012


If any column contains NULL value it want to stop concatenating at that colum and it want to goes to next record to concatenate.

How cany we do this by using "||" Concatenate.

Thanks in advance.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 3 2009
Added on Aug 6 2009
10 comments
50,853 views