Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Concatinate

Status
Not open for further replies.

erics55

Programmer
Nov 20, 2006
30
SE
Hi Is there way of performing concatination in a query like as follows

I have a table

ID |Num
__________________
1 A
1 B
2 C
2 D

I want to write a query that will produce the results

ID |Num
__________________
1 AB
2 CD

Thanks in advance

 
Have a look at this:

faq183-2146

And post back with any questions.

Hope it helps,

Alex

Ignorance of certain subjects is a great part of wisdom
 
Hi mate

Thanks for the reply, my table is huge and i dont know if this would be a very ecconomical method. what do you think?
 
If you don't want to do that, try this FAQ. faq183-6466

The WHILE Loop should help you out.



Catadmin - MCDBA, MCSA
"No, no. Yes. No, I tried that. Yes, both ways. No, I don't know. No again. Are there any more questions?"
-- Xena, "Been There, Done That"
 
No, In TSQL you didn't have Concatenate function. If you want to Concatenate read faq183-6466 to see how to do it.

Borislav Borissov
VFP9 SP1, SQL Server 2000/2005.
MVP VFP
 
Sorry about this. I answered on wrong thread :-( SHAME

Borislav Borissov
VFP9 SP1, SQL Server 2000/2005.
MVP VFP
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top