Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
DB Engine
SQL ServerMSDESQL Server CE
Services
Analysis (Data Mining)Analysis (OLAP)DTSIntegration ServicesNotification ServicesReporting Services
Programming
CLRConnectivitySQLXML
Other Technologies
ClusteringEnglish QueryFull-Text SearchReplicationService Broker
General
Data WarehousingPerformanceSecuritySetupSQL Server ToolsOther SQL Server Topics
DirectoryUser Groups
Related Topics
MS AccessOther DB ProductsMS Server Products.NET DevelopmentVB DevelopmentJava DevelopmentMore Topics ...

SQL Server Forum / General / Data Warehousing / November 2005

Tip: Looking for answers? Try searching our database.

Crosstab?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jon Derbyshire - 03 Nov 2005 14:49 GMT
Hi,

I run the following query "SELECT * FROM tbl_A", and get the following
result set:

Surname       Firstname
Smith           John
Smith           Richard
Smith           Simon

What I want to see in my result set is:

Surname       Firstname
Smith           John, Richard, Simon

How do I achieve this?

Thanks

Jon Derbyshire
Adam Machanic - 05 Nov 2005 20:54 GMT
Can you do it in the client?  This kind of thing is extremely inefficient in
SQL Server.

If you must do it in SQL Server, refer to the following:

http://www.aspfaq.com/show.asp?id=2529

Signature

Adam Machanic
Pro SQL Server 2005, available now
www.apress.com/book/bookDisplay.html?bID=457
--

> Hi,
>
[quoted text clipped - 16 lines]
>
> Jon Derbyshire
Jon Derbyshire - 07 Nov 2005 13:55 GMT
Thats brilliant - Thanks

> Can you do it in the client?  This kind of thing is extremely inefficient in
> SQL Server.
[quoted text clipped - 23 lines]
> >
> > Jon Derbyshire
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.