Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 One to Many Relation

Author  Topic 

kwikwisi
Constraint Violating Yak Guru

283 Posts

Posted - 2010-02-18 : 01:28:17
I have two tables joined and writing query to show multi col values in one result set seperated by comma. How can I concat?

Eg.

col1 col 2
1 AA,BB
2 AA
3 BB,CC,DD

Thanks in advance.

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-02-18 : 01:31:07
see

http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=81254

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2010-02-18 : 01:31:50
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=81254

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2010-02-18 : 01:32:07


Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-02-18 : 01:32:40
quote:
Originally posted by madhivanan



Madhivanan

Failing to plan is Planning to fail


beat by 43 s

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

Sachin.Nand

2937 Posts

Posted - 2010-02-18 : 02:19:49
quote:
Originally posted by visakh16

quote:
Originally posted by madhivanan



Madhivanan

Failing to plan is Planning to fail


beat by 43 s

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/





No hard feelings Visakh.Please take a holiday for some days
& if you do goPLEASE STAY AWAY FROM THE COMPUTER.Let others also post their answers.So many times it happened to me when I am thinking about some solution & as soon as I am about to post it guess what already an answer is posted guess by whom ??? Well no prizes for guesses.


PBUH
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-02-18 : 02:32:12
quote:
Originally posted by Idera

quote:
Originally posted by visakh16

quote:
Originally posted by madhivanan



Madhivanan

Failing to plan is Planning to fail


beat by 43 s

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/





No hard feelings Visakh.Please take a holiday for some days
& if you do goPLEASE STAY AWAY FROM THE COMPUTER.Let others also post their answers.So many times it happened to me when I am thinking about some solution & as soon as I am about to post it guess what already an answer is posted guess by whom ??? Well no prizes for guesses.


PBUH




Dont worry after a week I wont be able to involve as much as what I'm doing now. My new project is starting next week so I'll be quite busy from then on

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

Sachin.Nand

2937 Posts

Posted - 2010-02-18 : 02:38:11
quote:
Originally posted by visakh16

quote:
Originally posted by Idera

quote:
Originally posted by visakh16

quote:
Originally posted by madhivanan



Madhivanan

Failing to plan is Planning to fail


beat by 43 s

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/





No hard feelings Visakh.Please take a holiday for some days
& if you do goPLEASE STAY AWAY FROM THE COMPUTER.Let others also post their answers.So many times it happened to me when I am thinking about some solution & as soon as I am about to post it guess what already an answer is posted guess by whom ??? Well no prizes for guesses.


PBUH




Dont worry after a week I wont be able to involve as much as what I'm doing now. My new project is starting next week so I'll be quite busy from then on

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/





Then it seems that I(for that matter all the Yaks in SQLTEAM) will have to stay away from it for a week till your project starts.

PBUH
Go to Top of Page
   

- Advertisement -