Concatanation of the rows from one columns

Database
Enthusiast

Re: Concatanation of the rows from one columns

Maybe I can do a CREATE TABLE target_table AS

(Our SELECT  .... )

I'm not sure im following you. So what is the best way to do this ? a BTEQ ?

Thx,Anna

Senior Supporter

Re: Concatanation of the rows from one columns

Check Jimms comment in 

http://forums.teradata.com/forum/tools/bteq-export-issue

You could paste the SQL below into the BTEQ script - no need for a single row SQL - and try it.

Enthusiast

Re: Concatanation of the rows from one columns

Ok, thx I want to try this. Im using TD Version 13.0.0.11 from aPRIL 2010 - How can I reach bteq ?

Thx, Anna

Senior Supporter

Re: Concatanation of the rows from one columns

ask your it people or colleagues.

Enthusiast

Re: Concatanation of the rows from one columns

Thx I will :)

Anna

Highlighted
Enthusiast

Re: Concatanation of the rows from one columns

Hi, i need your help,

  I have data in the file like as follows

ID   NAMe                                       col3         col4          col5

1    penchala,Ramesh,yaganti,      bnbn       hjhh            ghhjhj

2    gaddam,nagarjuna,gaga         bnbnnm   hjhjhjh       kjfddjk

.

.

.

.

.

  Like this i have data my problem is i need to use the the delimeter  as   ',' but in one column the field value itself has the delimeter if use delemeter ',' that column two values is taking as different columns values how to do this can please help me?

Thanks in advance

Ram

Enthusiast

Re: Concatanation of the rows from one columns

While concatenating, if you are restricted to use the comma delimiter then you can probably do a string operation on the table and change the comma delimiter to pipe or some other one in the NAME column. 

Re: Concatanation of the rows from one columns

This is also depends how the exported data used. For example if you loading to Xcel you may add "  " around your string with comas....

Re: Concatanation of the rows from one columns

Not applicable

Re: Concatanation of the rows from one columns

hi i want a help ,

I am working on some data now . I got to do certain operations on a set of column .It is actually phone numbers.but has been created in integer and decimal datatypes . actually i want it to be in string datatype inorder to use substring or 'like' function .

My requirement is to get  the the first three digits of the phone number.As it is in decimal and integer type how i can i perform the requiremnt.